Fork me on GitHub
#babashka
<
2021-12-30
>
borkdude15:12:07

babashka 0.7.3: don't invoke java for bb.edn without deps

👍 5
borkdude20:12:29

A cool thing that babashka 0.7.3 allows you to do is make a global bb.edn file, e.g. in ~/.tasks/bb.edn

{:tasks {http-server {:extra-deps {babashka/http-server
                                   {:git/url ""
                                    :git/sha "d1f01b47492dec245f3f6d297849ee038243ee86"}}
                      :task babashka.http-server/-main}}}
and then with a tiny bash wrapper: ~/bin/gtask:
#!/usr/bin/env bash

bb --config ~/.tasks/bb.edn "$@"
And then from anywhere on your system:
$ gtask tasks
The following tasks are available:

http-server
$ gtask http-server
Starting http server at  8090 for .

😀 3
🆒 4
👀 1
babashka 1