Re: [Pharo-users] How I can tell to a startup script to target specific images

2015-12-02 Thread Dimitris Chloupis
"color := [:colorCode :text| FileStream stderr "set the color" nextPut: Character escape; nextPut: $[; print: colorCode; nextPut: $m; nextPutAll: text; crlf; "reset the color" nextPut: Character escape; nextPutAll: '[0m'. ]." Nice ideas in that startup ,

Re: [Pharo-users] How I can tell to a startup script to target specific images

2015-12-02 Thread Mariano Martinez Peck
On Wed, Dec 2, 2015 at 10:12 AM, Dimitris Chloupis wrote: > Mariano does not work like that for me. The startup script executes only > one time for each image that has not already executed the startup script. > So as soon as it installs the libraries and I save then image it does not > reinstall

Re: [Pharo-users] How I can tell to a startup script to target specific images

2015-12-02 Thread p...@highoctane.be
Ah, cool. Here is one I have around (was for Pharo2-3, fails in 4.0 somewhere) on my windows box. Nice little things in there, even if it would need some rework (I am using Linux most of the time now). Phil "Put this in ~/Library/Preferences/pharo/ " "or C:\Users\User\AppData\Roaming\pharo\pha

Re: [Pharo-users] How I can tell to a startup script to target specific images

2015-12-02 Thread Dimitris Chloupis
here is the script for anyone curious how it works https://www.dropbox.com/s/w88umn72kx2tw6s/startupPharo.st?dl=0 On Wed, Dec 2, 2015 at 3:12 PM Dimitris Chloupis wrote: > Mariano does not work like that for me. The startup script executes only > one time for each image that has not already exe

Re: [Pharo-users] How I can tell to a startup script to target specific images

2015-12-02 Thread Dimitris Chloupis
Mariano does not work like that for me. The startup script executes only one time for each image that has not already executed the startup script. So as soon as it installs the libraries and I save then image it does not reinstall them the next time I open the image and I have not noticed any delay

Re: [Pharo-users] How I can tell to a startup script to target specific images

2015-12-02 Thread Mariano Martinez Peck
Dimitris...a bit off topic... but... isn't it a bit too much to load all your packages every time you start your image? I am sure it takes some seconds if not minutes (depending what to load). Since Smalltalk gives us persistency for free (image), why isn't it enough to simply build and save an im

Re: [Pharo-users] How I can tell to a startup script to target specific images

2015-12-02 Thread Dimitris Chloupis
thanks phil that is very useful too, I will use it for managing my external pharo files :) On Wed, Dec 2, 2015 at 1:57 PM p...@highoctane.be wrote: > What's wrong about using FileLocator? > > I am a late-bound reference. I refer to a file or directory in relation to > a well-known location on th

Re: [Pharo-users] How I can tell to a startup script to target specific images

2015-12-02 Thread p...@highoctane.be
What's wrong about using FileLocator? I am a late-bound reference. I refer to a file or directory in relation to a well-known location on the filesystem, called an origin. When asked to perform concrete operation, I look up the current location of my origin, and resolve my path against it. Usage

Re: [Pharo-users] How I can tell to a startup script to target specific images

2015-12-02 Thread Dimitris Chloupis
Thank you both, checking the image name sounds like a great idea to limit the execution of my startup script. On Wed, Dec 2, 2015 at 12:52 PM Ferlicot D. Cyril wrote: > Le 02/12/2015 11:35, Dimitris Chloupis a écrit : > > I have a startup script that loads the libraries and project I mostly > >

Re: [Pharo-users] How I can tell to a startup script to target specific images

2015-12-02 Thread Ferlicot D. Cyril
Le 02/12/2015 11:35, Dimitris Chloupis a écrit : > I have a startup script that loads the libraries and project I mostly > use, including my own, but I want that script to target specific folders > and its subfolders , is this possible ? Hi, You can use "FileSystem workingDirectory" to get the di

Re: [Pharo-users] How I can tell to a startup script to target specific images

2015-12-02 Thread Peter Uhnak
On 12/02, Dimitris Chloupis wrote: > I have a startup script that loads the libraries and project I mostly use, > including my own, but I want that script to target specific folders and its > subfolders , is this possible ? You can test values of `SmalltalkImage current`... for example (Smalltal

[Pharo-users] How I can tell to a startup script to target specific images

2015-12-02 Thread Dimitris Chloupis
I have a startup script that loads the libraries and project I mostly use, including my own, but I want that script to target specific folders and its subfolders , is this possible ?