Logiraptor/chickenLISP — pull request #1 by bieber (2014-03-03 06:39:55+00:00)
Title: Turn chickenLISP Into a Self-Sufficient Program

Just a few minor changes I thought you might like to make chickenLISP
usable for general files/stdin and keep it from crashing if you run it
outside of the directory with its grammar file.

* Moved list.peg into a constant string in list.peg.go so it gets
compiled in.
* Moved eval and friends into interpreter.go, created a new main.go
with just the code responsible for interacting with the user and
invoking the interpreter.
* Added a command-line flag, -i, that lets the user specify an input
file or read from stdin.
* Switched error output to log.Fatal. That puts them on stderr
instead of intermingling with output on stdout, and saves you from
having to remember to break out of your main function after an
error.

The previous example program is now included in /examples/test.lisp.
You can run it with

chickenLISP -i [path/to/your/checkout/]examples/test.lisp

or

chickenLISP < [path/to/your/checkout/]examples/test.lisp

Running different source files or just typing a program on stdin and
hitting C-d should work as well.