Babashka

Babashka is a Clojure runtime specialised for writing lightweight scripting tasks.

Cookbook

Command-line entry point

The following snippet is analogous to Python's ~__name__ == "__main__" idiom. The code will execute when run from the command line, but not from the REPL.See babashka#478.

(when (= *file* (System/getProperty "babashka.file"))
  (-main))