public
Last active

Pharo Smalltalk REPL server

  • Download Gist
gistfile1.st
Smalltalk
1 2 3 4 5 6 7 8 9 10
"Works out of the box in Pharo 2.0. For prior versions (definitely works in 1.3 and 1.4), first file in https://gist.github.com/2602113"
 
| command |
[
command := FileStream stdin nextLine.
command ~= 'exit' ] whileTrue: [ | result |
result := Compiler evaluate: command.
FileStream stdout nextPutAll: result asString; lf ].
Smalltalk snapshot: false andQuit: true.

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.