[squeak-dev] The Inbox: System-dtl.1164.mcz

David T. Lewis lewis at mail.msen.com
Tue Jun 9 14:33:21 UTC 2020

On Tue, Jun 09, 2020 at 11:46:00AM +0530, K K Subbu wrote:
> On 09/06/20 1:16 am, commits at source.squeak.org wrote:
> >David T. Lewis uploaded a new version of System to project The Inbox:
> >http://source.squeak.org/inbox/System-dtl.1164.mcz
> >
> Suggest splitting the arguments into image, first and rest. If first is 
> nil, then no further processing is required. If it is a chunk or project 
> file, then treat it as a startup script or project and pass the rest of 
> the command line to it.
> E.g.
>     squeak.image playmedia.st  $HOME/music/foo.mp3
>     squeak.image starwars.pr $HOME/background/deathstar.png
>     squeak.image repl.st 'Beeper beep!'
> Regards .. Subbu

That is a good idea, but I think that this kind of argument handling can
best be accomplished with additional changes in the image after we get
the basic argument passing stabilized.

At this point, I am not trying to add any new features. I just want to
get the existing argument handling to work consistent with the original
design intent, and also consistently with respect to the various ways in
which a user might enter a command line from a terminal window.

Once that is done, we can think about adding new features or different
behavior. But I'm not sure that any new features will be needed. Consider
your idea of:
     $ squeak.image playmedia.st  $HOME/music/foo.mp3

I think you will find that the playmedia.st script can directly reference
Smalltalk argumentAt 1 to find the value of $HOME/music/foo.mp3 that
was passed to the image.


More information about the Squeak-dev mailing list