Hello all
I'd like to give an example for what Chris writes in the last paragraph or his message
"I'm sincerely intrigued by Smalltalk REPL's, but still skeptical that *I* would have the patience to use them given all the other tools at my disposal; VNC, error-handling, logging, intercepting kill signals, etc. That does not mean it is not useful for others or in other contexts, though."
I agree with that. A Smalltalk REPL might not be a tool to be used much by most Smalltalk developers but it may be a _very_ valuable asset for other groups of people for certain fields of application.
An example: In the JavaScript world there are millions of web developers who use a REPL [4] daily for all of their work.
There are build tools such as grunt [5] and gulp [6] and scaffolding tools such as yeoman [7].
Let's say I want to construct a similar tool or a tool on top of one of these tools in Smalltalk. E.g. the tool might generate a Gruntfile.js [1] and a package.json file [2].
For this I use a few Smalltalk classes put together in a few hours, days or weeks depending on the complexity of the web app to build.
As seen from outside it is a small or larger DSL [3] offered within a command line app. The DSL offers build commands for a web solution (HTML/CSS/JS).
For the target developer group this is seen as something very approachable. It is only needed to set some properties of builder objects and then issue build commands. The syntax is easy to learn and understand. The tool may be used from the command line like all the other tools.
From the Smalltalk developer perspective, i.e. the one who develops
the build tool the graphical environment is used to develop the code. It it then only _deployed_ as a Command line app.
The command line app lowers the bar for entry for the target group of developers. If the command line app is later on seen to be too limited then the graphical Smalltalk IDE may come into action.
Note that on the other side it is also possible to hide the fact that package.json and Gruntfile.js have been generated by a Smalltalk solution, i.e. generate them only once and later on work with these files directly.
Another note is that a Smalltalk REPL solution may be easier to write and deploy than a full 'graphical builder application'.
This means that there is a place for Smalltalk REPL solutions.
Regards Hannes
[1] A Gruntfile.js is something like a Makefile for the nodejs ecosystem.
[2] https://docs.npmjs.com/files/package.json https://nodesource.com/blog/the-basics-of-package-json-in-node-js-and-npm/ The package.json file is core to the Node.js ecosystem and is a basic part of understanding and working with Node.js, npm, and even modern JavaScript. https://www.npmjs.com/ npm is the package manager for JavaScript says it is the world’s largest software registry.
[3] The DSL in fact just being some Smalltalk expressions using a few domain specific classes,
[4] It should also be mentioned that Ruby, Python, Lua and other languages have the REPL as the main interaction tool.
[5] grunt https://gruntjs.com/ a task runner for repetitive tasks like minification, compilation, unit testing, linting, etc, the easier your job becomes. It uses a huge configuration file and the style is declarative.
[6] gulp https://gulpjs.com/ -- another build tool introduced later preferring code over configuration,
[7] yeoman -- http://yeoman.io/ a scaffolding tool for web apps.
On 4/13/18, Chris Muller ma.chris.m@gmail.com wrote:
Hi Eliot,
I went back to Benoit's words to look for what may have caused negative feelings to emerge. My guess is it must be the last two sentences. From what I know of you, you're in my "friend" psyche, and I read your words in that context. Try to read Benoit's expression of doubt as merely an invitation for someone to please provide some enlightenment. He did say it was "cool," to which I agree, and no one wants to shoot down cool. I want to learn. Please allow me to inquire the circumstances about when a Smalltalk REPL would be useful, and be _necessarily critical_ of that usefulness, without taking it personally but by further enlightenment; which, you did. :)
I'm sincerely intrigued by Smalltalk REPL's, but still skeptical that *I* would have the patience to use them given all the other tools at my disposal; VNC, error-handling, logging, intercepting kill signals, etc. That does not mean it is not useful for others or in other contexts, though.
- Chris
On Thu, Apr 12, 2018 at 3:35 AM, Eliot Miranda eliot.miranda@gmail.com wrote:
Hi Chris, Hi Benoît,
On Apr 8, 2018, at 5:13 PM, Chris Muller asqueaker@gmail.com wrote:
On Sun, Apr 8, 2018 at 3:28 PM, Benoit St-Jean via Squeak-dev squeak-dev@lists.squeakfoundation.org wrote:
Just to give my 2 cents on the subject, when I started this thread I was
just asking for an easy way to have an interactive headless console
application.
Start a server on localhost which can then accept commands from one or more terminals or elsewhere. This is how Magma and many other applications work. Multi-user and modal-less.
Quite frankly, I never had the need to compile Smalltalk expressions from a
prompt and I've never seen the benefits of it. If one wants to execute
Smalltalk code, we do have the capability to do it by providing a script as
an argument! Yes, it's quite nice to be able to do so when you want to show
off how cool is Smalltalk but is there any *real* use for such a
functionality? I doubt it!
+1.
You've probably seen this in the other thread. Forgive me; I don't mean to say "I told you so", and the REPL that I did implement is for my own usage, in which I find it much more convenient than scripts. But I don't like to see useful things shot down.
On Apr 12, 2018, at 1:16 AM, Sven Van Caekenberghe sven@stfx.eu wrote:
On 12 Apr 2018, at 03:15, Eliot Miranda eliot.miranda@gmail.com wrote:
Hi Sven,
On Wed, Apr 11, 2018 at 1:25 PM, Sven Van Caekenberghe sven@stfx.eu wrote:
On 11 Apr 2018, at 21:44, Stephane Ducasse stepharo.self@gmail.com wrote:
I did not know about the NeoConsole. Nice because I wanted to build a
little REPL for my minilanguage implementation.
You are of course welcome to look at it.
But it is Pharo specific.
I use it to be able to hook/look into running headless server images.
For this it is super handy.
Cool usage! Could you tell me whether you type Smalltalk expressions into this to examine your running server? The answer will be used in a related discussion on a mailing list not too distant from this one ;-)
Yes of course, that it the whole purpose, to type in expressions and to manipulate objects in a running image. I recently added options to look at code and change/add methods. All very primitive, but when in trouble, it works well.
So it turns out to be very useful.