babashka

https://github.com/babashka/babashka. Also see #sci, #nbb and #babashka-circleci-builds .
borkdude 2020-12-25T08:32:23.385900Z

apparently you can also def a map in project.clj?

borkdude 2020-12-25T08:33:57.386300Z

wow this works:

(def project '{:version "0.0.1"
               :dependencies [[org.clojure/clojure "1.10.2-rc1"]]})

😮 1
borkdude 2020-12-25T20:36:40.388100Z

Playing around with a pod resolver (downloads a pod if it's not downloaded yet). Example:

(require '[babashka.pods :as pods])

;; this will download the hsqldb pod, takes a while the first time, fast the second time
(pods/load-pod 'org.babashka/pod-babashka-hsqldb)

(require '[pod.babashka.hsqldb :as db])

(def db "jdbc:hsqldb:mem:testdb;sql.syntax_mys=true")

(db/execute! db ["create table foo ( foo int );"])

(db/execute! db ["insert into foo values (1, 2, 3);"])

(db/execute! db ["select * from foo;"])
The above example should work with: - linux version: https://13945-201467090-gh.circle-artifacts.com/0/release/babashka-0.2.6-SNAPSHOT-linux-amd64.zip - macos version: https://13944-201467090-gh.circle-artifacts.com/0/release/babashka-0.2.6-SNAPSHOT-macos-amd64.zip (windows TODO, should work, but the pod doesn't have a Windows version)

🎉 7
borkdude 2020-12-25T20:37:35.388300Z

(merry xmas btw!)

👍 1
🎄 6