|I just pushed an improvement to Anarki's Unix script^1. It now uses getopts^2 to parse arguments, and now it can take two args. The complete help text:|
So I'm now able to use Anarki inside emacs, if I pass the -n argument, so it doesn't use rlwrap. This will stop my constant carping about how I don't use Anarki, and downgrade it to constant confusion about what's changed from Arc3.1.
arc [-n] [-h] [<file> [<file_args>]]
Print help and exit
Don't start up a REPL; instead, execute the file, passing to it any file_args. When the file finishes executing, exit Arc.
Start the Arc REPL.
Start the Arc REPL without rlwrap
Run the file "file-to-run.arc", passing to it the argument 3
arc file-to-run.arc 3
As a side note, how do you receive arguments inside a script? In the example above (arc file-to-run.arc 3), how do I get the value 3 inside file-to-run.arc? The file itself runs fine; I just don't know how to get arguments.