diff --git a/README.md b/README.md index 22a20201..148f16d2 100644 --- a/README.md +++ b/README.md @@ -229,7 +229,7 @@ bb '(load-file "script.clj")' Using `bb` with a shebang also works: ``` clojure -#!/usr/bin/env bb -f +#!/usr/bin/env bb (defn get-url [url] (println "Fetching url:" url) @@ -260,6 +260,22 @@ Fetching url: https://www.clojure.org Writing file: /tmp/clojure.org.html ``` +If `/usr/bin/env` doesn't work for you, you can use the following workaround: + +``` shellsession +$ cat script.clj +#!/bin/sh + +#_( + "exec" "bb" "$0" hello "$@" + ) + +(prn *command-line-args*) + +./script.clj 1 2 3 +("hello" "1" "2" "3") +``` + ## Preloads The environment variable `BABASHKA_PRELOADS` allows to define code that will be diff --git a/resources/BABASHKA_VERSION b/resources/BABASHKA_VERSION index ff50928e..cd231804 100644 --- a/resources/BABASHKA_VERSION +++ b/resources/BABASHKA_VERSION @@ -1 +1 @@ -0.0.17-SNAPSHOT +0.0.17