v0.0.17
This commit is contained in:
parent
5ca10617d3
commit
876c2fe7a0
2 changed files with 18 additions and 2 deletions
18
README.md
18
README.md
|
|
@ -229,7 +229,7 @@ bb '(load-file "script.clj")'
|
||||||
Using `bb` with a shebang also works:
|
Using `bb` with a shebang also works:
|
||||||
|
|
||||||
``` clojure
|
``` clojure
|
||||||
#!/usr/bin/env bb -f
|
#!/usr/bin/env bb
|
||||||
|
|
||||||
(defn get-url [url]
|
(defn get-url [url]
|
||||||
(println "Fetching url:" url)
|
(println "Fetching url:" url)
|
||||||
|
|
@ -260,6 +260,22 @@ Fetching url: https://www.clojure.org
|
||||||
Writing file: /tmp/clojure.org.html
|
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
|
## Preloads
|
||||||
|
|
||||||
The environment variable `BABASHKA_PRELOADS` allows to define code that will be
|
The environment variable `BABASHKA_PRELOADS` allows to define code that will be
|
||||||
|
|
|
||||||
|
|
@ -1 +1 @@
|
||||||
0.0.17-SNAPSHOT
|
0.0.17
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue