Hi Alex, I am interested in using Smalltalk as a scripting language for routine tasks (to replace sh, perl, python, ruby etc.). It seems that you want to use it as an interactive shell language (to replace sh, bash, tcsh etc.). These are somewhat different goals. I am not sure if they are compatible, but it is interesting to explore. Does anyone know of any previous attempts to use Smalltalk or Smalltalk-like syntax for an interactive shell? David Lewis mentioned ExternalCommandShell as an example. Is that the state-of-the-art? - on On Feb 25, 2009, at 22:14, Alexandre Bergel wrote: > My dream is to completely get rid of bash and other awful shells. > > I remember to have seen a talk on a OO shell, where each command like > 'cat', 'ls', 'cd' where actually message sent to an instance of a > class Shell. The receiver would then be implicit. > Imagine a prompt like: > shell. > > Each command will then be a message sent to the object referenced by > the variable 'shell'. > > entering 'ls' will then invoke 'shell.ls'... > > Cheers, > Alexandre _______________________________________________ Pharo-project mailing list [hidden email] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project |
In reply to this post by johnmci
because you change the way the file is looked up
this way we can now use vm -headless -file ljkljljkl without been forced to provide the full path but may I'm wrong since I\m doing too much stuff On Feb 25, 2009, at 5:19 PM, John M McIntosh wrote: > > On 25-Feb-09, at 4:55 AM, Oscar Nierstrasz wrote: > >> This will load everything that is required and pop up a few Workspace >> windows with further instructions. (You will need John McIntosh's >> latest VM to get this to work -- all is described in the image.) > > Well I'm curious why won't older VM's work? > > -- > = > = > = > = > = > ====================================================================== > John M. McIntosh <[hidden email]> > Corporate Smalltalk Consulting Ltd. http:// > www.smalltalkconsulting.com > = > = > = > = > = > ====================================================================== > > > > > _______________________________________________ > Pharo-project mailing list > [hidden email] > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project > _______________________________________________ Pharo-project mailing list [hidden email] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project |
In reply to this post by Michael van der Gulik-2
sound interesting
thanks for the pointer On Feb 25, 2009, at 10:09 PM, Michael van der Gulik wrote: > > > On Thu, Feb 26, 2009 at 9:26 AM, Alexandre Bergel > <[hidden email]> wrote: > > please > > try it out and let me know what you would expect from a real > Smalltalk > > scripting environment. > > > Something that would really push me in using Coral is an intelligent > prompt. A list of the things the prompt should do: > - crawling into the history of typed commands using up and > down key > arrow > - tab completion (classes and method name) > - colored output > - Ctl-D to quit > - Keybinds: > * Ctlr-A beginning of the line > * Ctrl-E end of the line > * Alt- -> / Alt- <- to jump words > > > I modified REPLServer to do all of the above except for CTRL-d, > colour and Alt-word skipping. I originally made it so that I could > do stuff that breaks Morphic then still be able to use and recover > the image. > > REPLServer uses telnet but can be modified to use other input/output > mechanisms such as stdin/stdout or Display/EventSensor. > > REPLServer is loadable in Squeak 3.9, 3.10 using the Packages > Universe, or http://www.squeaksource.com/SecureSqueak (I should > really put it in its own project at some stage). Its documentation > is available as "online help" from the CLI. > > Gulik. > > -- > http://gulik.pbwiki.com/ > _______________________________________________ > Pharo-project mailing list > [hidden email] > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project _______________________________________________ Pharo-project mailing list [hidden email] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project |
In reply to this post by Nicolas Cellier-3
sounds fun. For the syntax, if we could keep the one of Smalltalk this
would be great because find . *.tex -print name -exec {} looks like something you want to avoid. else bash is good enough for me right now I want to code in pharo the lib to be able to write little scripts to script them. :) On Feb 25, 2009, at 10:48 PM, Nicolas Cellier wrote: > Marcus Denker <denker@...> writes: > >> >> >> On 25.02.2009, at 22:27, Matthew Fulmer wrote: >> >>>> >>>> Each command will then be a message sent to the object referenced >>>> by >>>> the variable 'shell'. >>>> >>>> entering 'ls' will then invoke 'shell.ls'... >> >> I would say that a command like "ls" is not a method. It's an object >> (instance of a sublass of "Script" or "Command"). >> >> You want, for example, inherit things like command line parsing, >> standard options >> (e.g. --help) and things liket that. A command like ls is far too >> complex to be >> just one method. >> >> Marcus >> >> -- >> Marcus Denker -- denker@... >> http://www.marcusdenker.de >> > > I would say ls is a message, and Shell ls answer with a LSCommand > which is > kindOf: Command. > A Command use lazy evaluation: it does not evaluate until a end of > line or pipe > message triggers evaluation (i mean send the message #value). > > Before being evaluated, Command behaviour can be modified by sending > all sort of > message, like -l --help etc... > Of course, apart options which are messages sent to the command > (eventually with > arguments), a list of arguments can be passed to the Command itself > (Command > valueWithArguments: aList). > > Just have to invent the syntax now... > > Nicolas > > > _______________________________________________ > Pharo-project mailing list > [hidden email] > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project > _______________________________________________ Pharo-project mailing list [hidden email] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project |
In reply to this post by Oscar Nierstrasz
On Thu, Feb 26, 2009 at 12:03:43PM +0100, Oscar Nierstrasz wrote:
> > David Lewis mentioned ExternalCommandShell as an example. Is that the > state-of-the-art? Well, I wrote it so you may be sure that it is not state-of-the-art ;) Dave _______________________________________________ Pharo-project mailing list [hidden email] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project |
:)
soa is relative to the context :) Stef PS: I like the energy we are creating here. >> David Lewis mentioned ExternalCommandShell as an example. Is that >> the >> state-of-the-art? > > Well, I wrote it so you may be sure that it is not state-of-the-art ;) > > Dave _______________________________________________ Pharo-project mailing list [hidden email] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project |
In reply to this post by David T. Lewis
Haha! I just meant, is there anything else out there I should know about? Do you know about any other Smalltalk-based shells? - on On Feb 26, 2009, at 13:35, David T. Lewis wrote: > On Thu, Feb 26, 2009 at 12:03:43PM +0100, Oscar Nierstrasz wrote: >> >> David Lewis mentioned ExternalCommandShell as an example. Is that >> the >> state-of-the-art? > > Well, I wrote it so you may be sure that it is not state-of-the-art ;) > > Dave _______________________________________________ Pharo-project mailing list [hidden email] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project |
Hello Oscar,
I know about STSH Shell for Smalltalk/X: http://www.vanak.cz/downloads.html (distributed as a binary release) and Sh++ which is a "visual" shell using the FOIBLE framework for visual languages: http://ftp3.gwdg.de/pub/languages/smalltalk/st.cs.uiuc.edu/Smalltalk/st80_pre4/Foible/Sh++/Sh++/ Hernán 2009/2/26 Oscar Nierstrasz <[hidden email]>: > > Haha! I just meant, is there anything else out there I should know > about? > > Do you know about any other Smalltalk-based shells? > > - on > > On Feb 26, 2009, at 13:35, David T. Lewis wrote: > >> On Thu, Feb 26, 2009 at 12:03:43PM +0100, Oscar Nierstrasz wrote: >>> >>> David Lewis mentioned ExternalCommandShell as an example. Is that >>> the >>> state-of-the-art? >> >> Well, I wrote it so you may be sure that it is not state-of-the-art ;) >> >> Dave > > > _______________________________________________ > Pharo-project mailing list > [hidden email] > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project > _______________________________________________ Pharo-project mailing list [hidden email] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project |
In reply to this post by Oscar Nierstrasz
>
> Do you know about any other Smalltalk-based shells? > sounds like an excellent GSOC / ESUG Summertalk project candidate ;) Cédrick _______________________________________________ Pharo-project mailing list [hidden email] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project |
Free forum by Nabble | Edit this page |