ol(1)

πŸ“¦
version 0.2.2 Β· 2 versions
, in arch rolling, nixos 26.05, nixpkgs unstable

πŸ’– NAME πŸ’–

okay bestie, meet ol(1) β€” literally an Owl Lisp compiler and interpreter, no cap. πŸ¦‰βœ¨

πŸ¦‹ SYNOPSIS πŸ¦‹

ol [options] [path] ...

✨ DESCRIPTION ✨

Owl Lisp is a purely functional variant of R7RS Scheme β€” yes, purely functional, main character energy fr fr. ol can be used to evaluate programs interactively and compile them to native binaries via C. Slay. πŸ’…

πŸŽ€ OPTIONS πŸŽ€

okay so this program follows the usual GNU command line syntax, with long options starting with two dashes (--). Here’s a summary of essential command-line flags, bestie β€” the complete list is shown on the help page. πŸ‘‘

  • -h, --help β€” show summary of options. iconic.
  • -v, --version β€” show version of program. 🫢
  • -e, --eval string β€” evaluate the string, print its value, and exit with 0 unless errors occurred. ✨
  • -t, --test string β€” evaluate the string and exit with 1 if the value is #false, 0 if it’s true, or 126 if there is an error. it’s giving test-runner realness 😭
  • -o, --output output-file β€” compile the given file to fasl or C code, and save the result to the given output file. πŸ”₯
  • -r, --run path β€” load the file silently, and call the last value with the remaining command line arguments. 🌸
  • -x, --output-format format β€” choose what ol should compile the given input to. valid options are currently c and fasl. this is normally deduced from the file suffix given in -o, and is thus not usually needed. lowkey optional πŸ’…
  • -O0, -O1, -O2 β€” write plain bytecode, compile some common functions to C or everything possible. these only make sense when compiling to C. πŸ”₯
  • -l, --load path β€” resume execution of program state saved with suspend. 🧚

🌈 EXAMPLES 🌈

Make a simple binary

$ echo '(lambda (args) (for-each print args))' > test.l
$ ol -o test.c test.l
$ gcc -o test test.c
$ ./test foo bar

Compile in a pipe

$ echo '(lambda (args) (print (cons "I got " args)))' | ol -x c
-o - | gcc -x c -o test - && ./test 11 22 33

Loading vs running files

$ echo '(print "Hello, world!")' > test.l
$ ol test.l
Hello, world!
$ echo '(lambda (args) (print "Hello, world!"))' > test.l
$ ol --run test.l arg1 arg2 arg3
Hello, world!

🫢 SEE ALSO 🫢

go peek at these too, bestie: ovm(1), gcc(1), scheme48(1). πŸ’–

πŸ‘‘ AUTHOR πŸ‘‘

Owl Lisp and this manual page were written by Aki Helin <aki.helin@iki.fi>. πŸŽ€


okay that’s the whole ol(1) page, bestie β€” signing off from the General Commands Manual, dated Jan 12, 2021, and yes the vibes are immaculate. stay slay πŸ’…βœ¨

πŸ“¦ where this page comes from