Updating packages from command line

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

Updating packages from command line

Bernat Romagosa
Is there a way to do it?

Here's my attempt:

pharo-vm-nox MyImage.image eval "Gofer new smalltalkhubUser: 'myUser' project: 'MyProject'; package: 'MyPackage'; load. Smalltalk snapshot: true andQuit: true"

then:

pharo-vm-nox MyImage.image eval --no-quit "MyJustLoadedClass start"

results in:

UndefinedObject>>DoIt (MyJustLoadedClass is Undeclared)
MessageNotUnderstood: receiver of "start" is nil

Thanks!
Bernat.

--
Bernat Romagosa.
Reply | Threaded
Open this post in threaded view
|

Re: Updating packages from command line

Goubier Thierry
What I use is eval --save:

pharo-vm-nox MyImage.image eval --save "Gofer new smalltalkhubUser: 'myUser' project: 'MyProject'; package: 'MyPackage'; load

Thierry

De : Pharo-users [[hidden email]] de la part de Bernat Romagosa [[hidden email]]
Envoyé : vendredi 2 mai 2014 13:28
À : Any question about pharo is welcome
Objet : [Pharo-users] Updating packages from command line

Is there a way to do it?

Here's my attempt:

pharo-vm-nox MyImage.image eval "Gofer new smalltalkhubUser: 'myUser' project: 'MyProject'; package: 'MyPackage'; load. Smalltalk snapshot: true andQuit: true"

then:

pharo-vm-nox MyImage.image eval --no-quit "MyJustLoadedClass start"

results in:

UndefinedObject>>DoIt (MyJustLoadedClass is Undeclared)
MessageNotUnderstood: receiver of "start" is nil

Thanks!
Bernat.

--
Bernat Romagosa.
Reply | Threaded
Open this post in threaded view
|

Re: Updating packages from command line

Sven Van Caekenberghe-2
In reply to this post by Bernat Romagosa
The best approach is to use Configurations and the config handler:

$ ./pharo Pharo.image config
Command line handler for dealing with Metacello configurations from the command line

Usage: config [--help] <repository url> [<configuration>] [--install[=<version>]] [--group=<group>] [--username=<username>] [--password=<password>]
        --help              show this help message
        <repository url>    A Monticello repository name
        <configuration>     A valid Metacello Configuration name
        <version>           A valid version for the given configuration
        <group>             A valid Metacello group name
        <username>          An optional username to access the configuration's repository
        <password>          An optional password to access the configuration's repository
       
Examples:
        # display this help message
        pharo Pharo.image config
       
        # list all configurations of a repository
        pharo Pharo.image config $MC_REPOS_URL
       
        # list all the available versions of a confgurtation
        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo
       
        # install the stable version
        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install
       
        #install a specific version '1.5'
        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5
       
        #install a specific version '1.5' and only a specific group 'Tests'
        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5 --group=Tests

The following article contains this approach as well:

 http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/

 http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/#deployingforproduction

HTH,

Sven

On 02 May 2014, at 13:28, Bernat Romagosa <[hidden email]> wrote:

> Is there a way to do it?
>
> Here's my attempt:
>
> pharo-vm-nox MyImage.image eval "Gofer new smalltalkhubUser: 'myUser' project: 'MyProject'; package: 'MyPackage'; load. Smalltalk snapshot: true andQuit: true"
>
> then:
>
> pharo-vm-nox MyImage.image eval --no-quit "MyJustLoadedClass start"
>
> results in:
>
> UndefinedObject>>DoIt (MyJustLoadedClass is Undeclared)
> MessageNotUnderstood: receiver of "start" is nil
>
> Thanks!
> Bernat.
>
> --
> Bernat Romagosa.


Reply | Threaded
Open this post in threaded view
|

Re: Updating packages from command line

Bernat Romagosa
I see, thanks a lot! :)


2014-05-02 13:45 GMT+02:00 Sven Van Caekenberghe <[hidden email]>:
The best approach is to use Configurations and the config handler:

$ ./pharo Pharo.image config
Command line handler for dealing with Metacello configurations from the command line

Usage: config [--help] <repository url> [<configuration>] [--install[=<version>]] [--group=<group>] [--username=<username>] [--password=<password>]
        --help              show this help message
        <repository url>    A Monticello repository name
        <configuration>     A valid Metacello Configuration name
        <version>           A valid version for the given configuration
        <group>             A valid Metacello group name
        <username>          An optional username to access the configuration's repository
        <password>          An optional password to access the configuration's repository

Examples:
        # display this help message
        pharo Pharo.image config

        # list all configurations of a repository
        pharo Pharo.image config $MC_REPOS_URL

        # list all the available versions of a confgurtation
        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo

        # install the stable version
        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install

        #install a specific version '1.5'
        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5

        #install a specific version '1.5' and only a specific group 'Tests'
        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5 --group=Tests

The following article contains this approach as well:

 http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/

 http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/#deployingforproduction

HTH,

Sven

On 02 May 2014, at 13:28, Bernat Romagosa <[hidden email]> wrote:

> Is there a way to do it?
>
> Here's my attempt:
>
> pharo-vm-nox MyImage.image eval "Gofer new smalltalkhubUser: 'myUser' project: 'MyProject'; package: 'MyPackage'; load. Smalltalk snapshot: true andQuit: true"
>
> then:
>
> pharo-vm-nox MyImage.image eval --no-quit "MyJustLoadedClass start"
>
> results in:
>
> UndefinedObject>>DoIt (MyJustLoadedClass is Undeclared)
> MessageNotUnderstood: receiver of "start" is nil
>
> Thanks!
> Bernat.
>
> --
> Bernat Romagosa.





--
Bernat Romagosa.
Reply | Threaded
Open this post in threaded view
|

Re: Updating packages from command line

Bernat Romagosa
Hmm it doesn't seem to work...

KeyNotFound: key #ConfigurationOfStarUOCs not found in SystemDictionary

But the config is there and I can load it from the GUI by doing:


Gofer new
smalltalkhubUser: 'bromagosa' project: 'StarUOCs';
package: 'ConfigurationOfStarUOCs';
load.

ConfigurationOfStarUOCs load.

What can be happening? My version is:

pharo-vm-nox Pharo.image printVersion
[version] 3.0 #30846



2014-05-02 13:51 GMT+02:00 Bernat Romagosa <[hidden email]>:
I see, thanks a lot! :)


2014-05-02 13:45 GMT+02:00 Sven Van Caekenberghe <[hidden email]>:

The best approach is to use Configurations and the config handler:

$ ./pharo Pharo.image config
Command line handler for dealing with Metacello configurations from the command line

Usage: config [--help] <repository url> [<configuration>] [--install[=<version>]] [--group=<group>] [--username=<username>] [--password=<password>]
        --help              show this help message
        <repository url>    A Monticello repository name
        <configuration>     A valid Metacello Configuration name
        <version>           A valid version for the given configuration
        <group>             A valid Metacello group name
        <username>          An optional username to access the configuration's repository
        <password>          An optional password to access the configuration's repository

Examples:
        # display this help message
        pharo Pharo.image config

        # list all configurations of a repository
        pharo Pharo.image config $MC_REPOS_URL

        # list all the available versions of a confgurtation
        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo

        # install the stable version
        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install

        #install a specific version '1.5'
        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5

        #install a specific version '1.5' and only a specific group 'Tests'
        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5 --group=Tests

The following article contains this approach as well:

 http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/

 http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/#deployingforproduction

HTH,

Sven

On 02 May 2014, at 13:28, Bernat Romagosa <[hidden email]> wrote:

> Is there a way to do it?
>
> Here's my attempt:
>
> pharo-vm-nox MyImage.image eval "Gofer new smalltalkhubUser: 'myUser' project: 'MyProject'; package: 'MyPackage'; load. Smalltalk snapshot: true andQuit: true"
>
> then:
>
> pharo-vm-nox MyImage.image eval --no-quit "MyJustLoadedClass start"
>
> results in:
>
> UndefinedObject>>DoIt (MyJustLoadedClass is Undeclared)
> MessageNotUnderstood: receiver of "start" is nil
>
> Thanks!
> Bernat.
>
> --
> Bernat Romagosa.





--
Bernat Romagosa.



--
Bernat Romagosa.
Reply | Threaded
Open this post in threaded view
|

Re: Updating packages from command line

EstebanLM
pharo-vm-nox Pharo.image config http://smalltalkhub.com/mc/bromagosa/StarUOCs/main  ConfigurationOfStarUOCs —install=development

has to work. All out infrastructure is based on that :)

Esteban

On 02 May 2014, at 15:05, Bernat Romagosa <[hidden email]> wrote:

> Hmm it doesn't seem to work...
>
> pharo-vm-nox Pharo.image config http://smalltalkhub.com/mc/bromagosa/StarUOCs/main
> KeyNotFound: key #ConfigurationOfStarUOCs not found in SystemDictionary
>
> But the config is there and I can load it from the GUI by doing:
>
>
> Gofer new
> smalltalkhubUser: 'bromagosa' project: 'StarUOCs';
> package: 'ConfigurationOfStarUOCs';
> load.
>
> ConfigurationOfStarUOCs load.
>
> What can be happening? My version is:
>
> pharo-vm-nox Pharo.image printVersion
> [version] 3.0 #30846
>
>
>
> 2014-05-02 13:51 GMT+02:00 Bernat Romagosa <[hidden email]>:
> I see, thanks a lot! :)
>
>
> 2014-05-02 13:45 GMT+02:00 Sven Van Caekenberghe <[hidden email]>:
>
> The best approach is to use Configurations and the config handler:
>
> $ ./pharo Pharo.image config
> Command line handler for dealing with Metacello configurations from the command line
>
> Usage: config [--help] <repository url> [<configuration>] [--install[=<version>]] [--group=<group>] [--username=<username>] [--password=<password>]
>         --help              show this help message
>         <repository url>    A Monticello repository name
>         <configuration>     A valid Metacello Configuration name
>         <version>           A valid version for the given configuration
>         <group>             A valid Metacello group name
>         <username>          An optional username to access the configuration's repository
>         <password>          An optional password to access the configuration's repository
>
> Examples:
>         # display this help message
>         pharo Pharo.image config
>
>         # list all configurations of a repository
>         pharo Pharo.image config $MC_REPOS_URL
>
>         # list all the available versions of a confgurtation
>         pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo
>
>         # install the stable version
>         pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install
>
>         #install a specific version '1.5'
>         pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5
>
>         #install a specific version '1.5' and only a specific group 'Tests'
>         pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5 --group=Tests
>
> The following article contains this approach as well:
>
>  http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/
>
>  http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/#deployingforproduction
>
> HTH,
>
> Sven
>
> On 02 May 2014, at 13:28, Bernat Romagosa <[hidden email]> wrote:
>
> > Is there a way to do it?
> >
> > Here's my attempt:
> >
> > pharo-vm-nox MyImage.image eval "Gofer new smalltalkhubUser: 'myUser' project: 'MyProject'; package: 'MyPackage'; load. Smalltalk snapshot: true andQuit: true"
> >
> > then:
> >
> > pharo-vm-nox MyImage.image eval --no-quit "MyJustLoadedClass start"
> >
> > results in:
> >
> > UndefinedObject>>DoIt (MyJustLoadedClass is Undeclared)
> > MessageNotUnderstood: receiver of "start" is nil
> >
> > Thanks!
> > Bernat.
> >
> > --
> > Bernat Romagosa.
>
>
>
>
>
> --
> Bernat Romagosa.
>
>
>
> --
> Bernat Romagosa.


Reply | Threaded
Open this post in threaded view
|

Re: Updating packages from command line

Sven Van Caekenberghe-2
I think something must be broken with his configuration, you cannot even list it...

On 02 May 2014, at 15:11, Esteban Lorenzano <[hidden email]> wrote:

> pharo-vm-nox Pharo.image config http://smalltalkhub.com/mc/bromagosa/StarUOCs/main  ConfigurationOfStarUOCs —install=development
>
> has to work. All out infrastructure is based on that :)
>
> Esteban
>
> On 02 May 2014, at 15:05, Bernat Romagosa <[hidden email]> wrote:
>
>> Hmm it doesn't seem to work...
>>
>> pharo-vm-nox Pharo.image config http://smalltalkhub.com/mc/bromagosa/StarUOCs/main
>> KeyNotFound: key #ConfigurationOfStarUOCs not found in SystemDictionary
>>
>> But the config is there and I can load it from the GUI by doing:
>>
>>
>> Gofer new
>> smalltalkhubUser: 'bromagosa' project: 'StarUOCs';
>> package: 'ConfigurationOfStarUOCs';
>> load.
>>
>> ConfigurationOfStarUOCs load.
>>
>> What can be happening? My version is:
>>
>> pharo-vm-nox Pharo.image printVersion
>> [version] 3.0 #30846
>>
>>
>>
>> 2014-05-02 13:51 GMT+02:00 Bernat Romagosa <[hidden email]>:
>> I see, thanks a lot! :)
>>
>>
>> 2014-05-02 13:45 GMT+02:00 Sven Van Caekenberghe <[hidden email]>:
>>
>> The best approach is to use Configurations and the config handler:
>>
>> $ ./pharo Pharo.image config
>> Command line handler for dealing with Metacello configurations from the command line
>>
>> Usage: config [--help] <repository url> [<configuration>] [--install[=<version>]] [--group=<group>] [--username=<username>] [--password=<password>]
>>        --help              show this help message
>>        <repository url>    A Monticello repository name
>>        <configuration>     A valid Metacello Configuration name
>>        <version>           A valid version for the given configuration
>>        <group>             A valid Metacello group name
>>        <username>          An optional username to access the configuration's repository
>>        <password>          An optional password to access the configuration's repository
>>
>> Examples:
>>        # display this help message
>>        pharo Pharo.image config
>>
>>        # list all configurations of a repository
>>        pharo Pharo.image config $MC_REPOS_URL
>>
>>        # list all the available versions of a confgurtation
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo
>>
>>        # install the stable version
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install
>>
>>        #install a specific version '1.5'
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5
>>
>>        #install a specific version '1.5' and only a specific group 'Tests'
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5 --group=Tests
>>
>> The following article contains this approach as well:
>>
>> http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/
>>
>> http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/#deployingforproduction
>>
>> HTH,
>>
>> Sven
>>
>> On 02 May 2014, at 13:28, Bernat Romagosa <[hidden email]> wrote:
>>
>>> Is there a way to do it?
>>>
>>> Here's my attempt:
>>>
>>> pharo-vm-nox MyImage.image eval "Gofer new smalltalkhubUser: 'myUser' project: 'MyProject'; package: 'MyPackage'; load. Smalltalk snapshot: true andQuit: true"
>>>
>>> then:
>>>
>>> pharo-vm-nox MyImage.image eval --no-quit "MyJustLoadedClass start"
>>>
>>> results in:
>>>
>>> UndefinedObject>>DoIt (MyJustLoadedClass is Undeclared)
>>> MessageNotUnderstood: receiver of "start" is nil
>>>
>>> Thanks!
>>> Bernat.
>>>
>>> --
>>> Bernat Romagosa.
>>
>>
>>
>>
>>
>> --
>> Bernat Romagosa.
>>
>>
>>
>> --
>> Bernat Romagosa.
>
>


Reply | Threaded
Open this post in threaded view
|

Re: Updating packages from command line

Bernat Romagosa
Indeed something's broken... I used the versionner tool to build it, but I think something went wrong.


Try to download the mcz, it fails.

I don't understand why MC added (2) to the file name.




2014-05-02 15:13 GMT+02:00 Sven Van Caekenberghe <[hidden email]>:
I think something must be broken with his configuration, you cannot even list it...

On 02 May 2014, at 15:11, Esteban Lorenzano <[hidden email]> wrote:

> pharo-vm-nox Pharo.image config http://smalltalkhub.com/mc/bromagosa/StarUOCs/main  ConfigurationOfStarUOCs —install=development
>
> has to work. All out infrastructure is based on that :)
>
> Esteban
>
> On 02 May 2014, at 15:05, Bernat Romagosa <[hidden email]> wrote:
>
>> Hmm it doesn't seem to work...
>>
>> pharo-vm-nox Pharo.image config http://smalltalkhub.com/mc/bromagosa/StarUOCs/main
>> KeyNotFound: key #ConfigurationOfStarUOCs not found in SystemDictionary
>>
>> But the config is there and I can load it from the GUI by doing:
>>
>>
>> Gofer new
>>      smalltalkhubUser: 'bromagosa' project: 'StarUOCs';
>>      package: 'ConfigurationOfStarUOCs';
>>      load.
>>
>> ConfigurationOfStarUOCs load.
>>
>> What can be happening? My version is:
>>
>> pharo-vm-nox Pharo.image printVersion
>> [version] 3.0 #30846
>>
>>
>>
>> 2014-05-02 13:51 GMT+02:00 Bernat Romagosa <[hidden email]>:
>> I see, thanks a lot! :)
>>
>>
>> 2014-05-02 13:45 GMT+02:00 Sven Van Caekenberghe <[hidden email]>:
>>
>> The best approach is to use Configurations and the config handler:
>>
>> $ ./pharo Pharo.image config
>> Command line handler for dealing with Metacello configurations from the command line
>>
>> Usage: config [--help] <repository url> [<configuration>] [--install[=<version>]] [--group=<group>] [--username=<username>] [--password=<password>]
>>        --help              show this help message
>>        <repository url>    A Monticello repository name
>>        <configuration>     A valid Metacello Configuration name
>>        <version>           A valid version for the given configuration
>>        <group>             A valid Metacello group name
>>        <username>          An optional username to access the configuration's repository
>>        <password>          An optional password to access the configuration's repository
>>
>> Examples:
>>        # display this help message
>>        pharo Pharo.image config
>>
>>        # list all configurations of a repository
>>        pharo Pharo.image config $MC_REPOS_URL
>>
>>        # list all the available versions of a confgurtation
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo
>>
>>        # install the stable version
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install
>>
>>        #install a specific version '1.5'
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5
>>
>>        #install a specific version '1.5' and only a specific group 'Tests'
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5 --group=Tests
>>
>> The following article contains this approach as well:
>>
>> http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/
>>
>> http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/#deployingforproduction
>>
>> HTH,
>>
>> Sven
>>
>> On 02 May 2014, at 13:28, Bernat Romagosa <[hidden email]> wrote:
>>
>>> Is there a way to do it?
>>>
>>> Here's my attempt:
>>>
>>> pharo-vm-nox MyImage.image eval "Gofer new smalltalkhubUser: 'myUser' project: 'MyProject'; package: 'MyPackage'; load. Smalltalk snapshot: true andQuit: true"
>>>
>>> then:
>>>
>>> pharo-vm-nox MyImage.image eval --no-quit "MyJustLoadedClass start"
>>>
>>> results in:
>>>
>>> UndefinedObject>>DoIt (MyJustLoadedClass is Undeclared)
>>> MessageNotUnderstood: receiver of "start" is nil
>>>
>>> Thanks!
>>> Bernat.
>>>
>>> --
>>> Bernat Romagosa.
>>
>>
>>
>>
>>
>> --
>> Bernat Romagosa.
>>
>>
>>
>> --
>> Bernat Romagosa.
>
>





--
Bernat Romagosa.
Reply | Threaded
Open this post in threaded view
|

Re: Updating packages from command line

Bernat Romagosa
I started over from scratch, filed out and in the config and package, erased all packages in the repo, pushed them back and still no success.

I think I'll manually scp the image file for now... :P

Thanks guys!


2014-05-02 15:21 GMT+02:00 Bernat Romagosa <[hidden email]>:
Indeed something's broken... I used the versionner tool to build it, but I think something went wrong.


Try to download the mcz, it fails.

I don't understand why MC added (2) to the file name.




2014-05-02 15:13 GMT+02:00 Sven Van Caekenberghe <[hidden email]>:

I think something must be broken with his configuration, you cannot even list it...

On 02 May 2014, at 15:11, Esteban Lorenzano <[hidden email]> wrote:

> pharo-vm-nox Pharo.image config http://smalltalkhub.com/mc/bromagosa/StarUOCs/main  ConfigurationOfStarUOCs —install=development
>
> has to work. All out infrastructure is based on that :)
>
> Esteban
>
> On 02 May 2014, at 15:05, Bernat Romagosa <[hidden email]> wrote:
>
>> Hmm it doesn't seem to work...
>>
>> pharo-vm-nox Pharo.image config http://smalltalkhub.com/mc/bromagosa/StarUOCs/main
>> KeyNotFound: key #ConfigurationOfStarUOCs not found in SystemDictionary
>>
>> But the config is there and I can load it from the GUI by doing:
>>
>>
>> Gofer new
>>      smalltalkhubUser: 'bromagosa' project: 'StarUOCs';
>>      package: 'ConfigurationOfStarUOCs';
>>      load.
>>
>> ConfigurationOfStarUOCs load.
>>
>> What can be happening? My version is:
>>
>> pharo-vm-nox Pharo.image printVersion
>> [version] 3.0 #30846
>>
>>
>>
>> 2014-05-02 13:51 GMT+02:00 Bernat Romagosa <[hidden email]>:
>> I see, thanks a lot! :)
>>
>>
>> 2014-05-02 13:45 GMT+02:00 Sven Van Caekenberghe <[hidden email]>:
>>
>> The best approach is to use Configurations and the config handler:
>>
>> $ ./pharo Pharo.image config
>> Command line handler for dealing with Metacello configurations from the command line
>>
>> Usage: config [--help] <repository url> [<configuration>] [--install[=<version>]] [--group=<group>] [--username=<username>] [--password=<password>]
>>        --help              show this help message
>>        <repository url>    A Monticello repository name
>>        <configuration>     A valid Metacello Configuration name
>>        <version>           A valid version for the given configuration
>>        <group>             A valid Metacello group name
>>        <username>          An optional username to access the configuration's repository
>>        <password>          An optional password to access the configuration's repository
>>
>> Examples:
>>        # display this help message
>>        pharo Pharo.image config
>>
>>        # list all configurations of a repository
>>        pharo Pharo.image config $MC_REPOS_URL
>>
>>        # list all the available versions of a confgurtation
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo
>>
>>        # install the stable version
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install
>>
>>        #install a specific version '1.5'
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5
>>
>>        #install a specific version '1.5' and only a specific group 'Tests'
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5 --group=Tests
>>
>> The following article contains this approach as well:
>>
>> http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/
>>
>> http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/#deployingforproduction
>>
>> HTH,
>>
>> Sven
>>
>> On 02 May 2014, at 13:28, Bernat Romagosa <[hidden email]> wrote:
>>
>>> Is there a way to do it?
>>>
>>> Here's my attempt:
>>>
>>> pharo-vm-nox MyImage.image eval "Gofer new smalltalkhubUser: 'myUser' project: 'MyProject'; package: 'MyPackage'; load. Smalltalk snapshot: true andQuit: true"
>>>
>>> then:
>>>
>>> pharo-vm-nox MyImage.image eval --no-quit "MyJustLoadedClass start"
>>>
>>> results in:
>>>
>>> UndefinedObject>>DoIt (MyJustLoadedClass is Undeclared)
>>> MessageNotUnderstood: receiver of "start" is nil
>>>
>>> Thanks!
>>> Bernat.
>>>
>>> --
>>> Bernat Romagosa.
>>
>>
>>
>>
>>
>> --
>> Bernat Romagosa.
>>
>>
>>
>> --
>> Bernat Romagosa.
>
>





--
Bernat Romagosa.



--
Bernat Romagosa.
Reply | Threaded
Open this post in threaded view
|

Re: Updating packages from command line

Goubier Thierry
Bernat,

if I encounter something like that, I would also erase the contents of my package-cache directory. Sometimes it seems I never manage to activate changes because it keeps on loading a package of the same name and number out of the cache instead.

Thierry



De : Pharo-users [[hidden email]] de la part de Bernat Romagosa [[hidden email]]
Envoyé : vendredi 2 mai 2014 15:39
À : Any question about pharo is welcome
Objet : Re: [Pharo-users] Updating packages from command line

I started over from scratch, filed out and in the config and package, erased all packages in the repo, pushed them back and still no success.

I think I'll manually scp the image file for now... :P

Thanks guys!


2014-05-02 15:21 GMT+02:00 Bernat Romagosa <[hidden email]>:
Indeed something's broken... I used the versionner tool to build it, but I think something went wrong.


Try to download the mcz, it fails.

I don't understand why MC added (2) to the file name.




2014-05-02 15:13 GMT+02:00 Sven Van Caekenberghe <[hidden email]>:

I think something must be broken with his configuration, you cannot even list it...

On 02 May 2014, at 15:11, Esteban Lorenzano <[hidden email]> wrote:

> pharo-vm-nox Pharo.image config http://smalltalkhub.com/mc/bromagosa/StarUOCs/main  ConfigurationOfStarUOCs —install=development
>
> has to work. All out infrastructure is based on that :)
>
> Esteban
>
> On 02 May 2014, at 15:05, Bernat Romagosa <[hidden email]> wrote:
>
>> Hmm it doesn't seem to work...
>>
>> pharo-vm-nox Pharo.image config http://smalltalkhub.com/mc/bromagosa/StarUOCs/main
>> KeyNotFound: key #ConfigurationOfStarUOCs not found in SystemDictionary
>>
>> But the config is there and I can load it from the GUI by doing:
>>
>>
>> Gofer new
>>      smalltalkhubUser: 'bromagosa' project: 'StarUOCs';
>>      package: 'ConfigurationOfStarUOCs';
>>      load.
>>
>> ConfigurationOfStarUOCs load.
>>
>> What can be happening? My version is:
>>
>> pharo-vm-nox Pharo.image printVersion
>> [version] 3.0 #30846
>>
>>
>>
>> 2014-05-02 13:51 GMT+02:00 Bernat Romagosa <[hidden email]>:
>> I see, thanks a lot! :)
>>
>>
>> 2014-05-02 13:45 GMT+02:00 Sven Van Caekenberghe <[hidden email]>:
>>
>> The best approach is to use Configurations and the config handler:
>>
>> $ ./pharo Pharo.image config
>> Command line handler for dealing with Metacello configurations from the command line
>>
>> Usage: config [--help] <repository url> [<configuration>] [--install[=<version>]] [--group=<group>] [--username=<username>] [--password=<password>]
>>        --help              show this help message
>>        <repository url>    A Monticello repository name
>>        <configuration>     A valid Metacello Configuration name
>>        <version>           A valid version for the given configuration
>>        <group>             A valid Metacello group name
>>        <username>          An optional username to access the configuration's repository
>>        <password>          An optional password to access the configuration's repository
>>
>> Examples:
>>        # display this help message
>>        pharo Pharo.image config
>>
>>        # list all configurations of a repository
>>        pharo Pharo.image config $MC_REPOS_URL
>>
>>        # list all the available versions of a confgurtation
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo
>>
>>        # install the stable version
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install
>>
>>        #install a specific version '1.5'
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5
>>
>>        #install a specific version '1.5' and only a specific group 'Tests'
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5 --group=Tests
>>
>> The following article contains this approach as well:
>>
>> http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/
>>
>> http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/#deployingforproduction
>>
>> HTH,
>>
>> Sven
>>
>> On 02 May 2014, at 13:28, Bernat Romagosa <[hidden email]> wrote:
>>
>>> Is there a way to do it?
>>>
>>> Here's my attempt:
>>>
>>> pharo-vm-nox MyImage.image eval "Gofer new smalltalkhubUser: 'myUser' project: 'MyProject'; package: 'MyPackage'; load. Smalltalk snapshot: true andQuit: true"
>>>
>>> then:
>>>
>>> pharo-vm-nox MyImage.image eval --no-quit "MyJustLoadedClass start"
>>>
>>> results in:
>>>
>>> UndefinedObject>>DoIt (MyJustLoadedClass is Undeclared)
>>> MessageNotUnderstood: receiver of "start" is nil
>>>
>>> Thanks!
>>> Bernat.
>>>
>>> --
>>> Bernat Romagosa.
>>
>>
>>
>>
>>
>> --
>> Bernat Romagosa.
>>
>>
>>
>> --
>> Bernat Romagosa.
>
>





--
Bernat Romagosa.



--
Bernat Romagosa.
Reply | Threaded
Open this post in threaded view
|

Re: Updating packages from command line

Bernat Romagosa
Hi Thierry,

I did so, and loaded the package the way you suggested. It worked alright :)

I guess my configuration is not well formed, I'll do it over.

Thanks!


2014-05-02 15:56 GMT+02:00 GOUBIER Thierry <[hidden email]>:
Bernat,

if I encounter something like that, I would also erase the contents of my package-cache directory. Sometimes it seems I never manage to activate changes because it keeps on loading a package of the same name and number out of the cache instead.

Thierry



De : Pharo-users [[hidden email]] de la part de Bernat Romagosa [[hidden email]]
Envoyé : vendredi 2 mai 2014 15:39

À : Any question about pharo is welcome
Objet : Re: [Pharo-users] Updating packages from command line

I started over from scratch, filed out and in the config and package, erased all packages in the repo, pushed them back and still no success.

I think I'll manually scp the image file for now... :P

Thanks guys!


2014-05-02 15:21 GMT+02:00 Bernat Romagosa <[hidden email]>:
Indeed something's broken... I used the versionner tool to build it, but I think something went wrong.


Try to download the mcz, it fails.

I don't understand why MC added (2) to the file name.




2014-05-02 15:13 GMT+02:00 Sven Van Caekenberghe <[hidden email]>:

I think something must be broken with his configuration, you cannot even list it...

On 02 May 2014, at 15:11, Esteban Lorenzano <[hidden email]> wrote:

> pharo-vm-nox Pharo.image config http://smalltalkhub.com/mc/bromagosa/StarUOCs/main  ConfigurationOfStarUOCs —install=development
>
> has to work. All out infrastructure is based on that :)
>
> Esteban
>
> On 02 May 2014, at 15:05, Bernat Romagosa <[hidden email]> wrote:
>
>> Hmm it doesn't seem to work...
>>
>> pharo-vm-nox Pharo.image config http://smalltalkhub.com/mc/bromagosa/StarUOCs/main
>> KeyNotFound: key #ConfigurationOfStarUOCs not found in SystemDictionary
>>
>> But the config is there and I can load it from the GUI by doing:
>>
>>
>> Gofer new
>>      smalltalkhubUser: 'bromagosa' project: 'StarUOCs';
>>      package: 'ConfigurationOfStarUOCs';
>>      load.
>>
>> ConfigurationOfStarUOCs load.
>>
>> What can be happening? My version is:
>>
>> pharo-vm-nox Pharo.image printVersion
>> [version] 3.0 #30846
>>
>>
>>
>> 2014-05-02 13:51 GMT+02:00 Bernat Romagosa <[hidden email]>:
>> I see, thanks a lot! :)
>>
>>
>> 2014-05-02 13:45 GMT+02:00 Sven Van Caekenberghe <[hidden email]>:
>>
>> The best approach is to use Configurations and the config handler:
>>
>> $ ./pharo Pharo.image config
>> Command line handler for dealing with Metacello configurations from the command line
>>
>> Usage: config [--help] <repository url> [<configuration>] [--install[=<version>]] [--group=<group>] [--username=<username>] [--password=<password>]
>>        --help              show this help message
>>        <repository url>    A Monticello repository name
>>        <configuration>     A valid Metacello Configuration name
>>        <version>           A valid version for the given configuration
>>        <group>             A valid Metacello group name
>>        <username>          An optional username to access the configuration's repository
>>        <password>          An optional password to access the configuration's repository
>>
>> Examples:
>>        # display this help message
>>        pharo Pharo.image config
>>
>>        # list all configurations of a repository
>>        pharo Pharo.image config $MC_REPOS_URL
>>
>>        # list all the available versions of a confgurtation
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo
>>
>>        # install the stable version
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install
>>
>>        #install a specific version '1.5'
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5
>>
>>        #install a specific version '1.5' and only a specific group 'Tests'
>>        pharo Pharo.image config $MC_REPOS_URL ConfigurationOfFoo --install=1.5 --group=Tests
>>
>> The following article contains this approach as well:
>>
>> http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/
>>
>> http://zn.stfx.eu/zn/build-and-deploy-1st-webapp/#deployingforproduction
>>
>> HTH,
>>
>> Sven
>>
>> On 02 May 2014, at 13:28, Bernat Romagosa <[hidden email]> wrote:
>>
>>> Is there a way to do it?
>>>
>>> Here's my attempt:
>>>
>>> pharo-vm-nox MyImage.image eval "Gofer new smalltalkhubUser: 'myUser' project: 'MyProject'; package: 'MyPackage'; load. Smalltalk snapshot: true andQuit: true"
>>>
>>> then:
>>>
>>> pharo-vm-nox MyImage.image eval --no-quit "MyJustLoadedClass start"
>>>
>>> results in:
>>>
>>> UndefinedObject>>DoIt (MyJustLoadedClass is Undeclared)
>>> MessageNotUnderstood: receiver of "start" is nil
>>>
>>> Thanks!
>>> Bernat.
>>>
>>> --
>>> Bernat Romagosa.
>>
>>
>>
>>
>>
>> --
>> Bernat Romagosa.
>>
>>
>>
>> --
>> Bernat Romagosa.
>
>





--
Bernat Romagosa.



--
Bernat Romagosa.



--
Bernat Romagosa.