babashka

https://github.com/babashka/babashka. Also see #sci, #nbb and #babashka-circleci-builds .
Marco Pas 2021-01-19T08:01:10.074700Z

Probably a clojure beginner question, but i was wondering why the following code snippet does not seem to work..

(require '[babashka.classpath :as cp])
(map cp/add-classpath ["test1" "test2"])
(print (cp/get-classpath))

$ bb runme.clj
--> result nil
As opposed to this one:
(require '[babashka.classpath :as cp])
(cp/add-classpath "test1")
(cp/add-classpath "test2")
(print (cp/get-classpath))

$ bb runme.clj
--> result test1:test2
When using the repl it works in both cases.. but not when using bb from the command line

borkdude 2021-01-19T08:06:52.075200Z

@marco.pasopas map is lazy. Try run!

👍 1
Marco Pas 2021-01-19T10:17:21.075700Z

Works, learned something new 🙂

borkdude 2021-01-19T22:15:45.077200Z

@nate I think you mentioned some problem with nippy in native image having something to do with Object serialization maybe? This is now possible in GraalVM 21.0.0 when you add classes that you want to serialize to the reflection config.

nate 2021-01-19T22:16:35.077300Z

oh cool!

nate 2021-01-19T22:16:42.077500Z

I'll have to try that out

nate 2021-01-19T22:16:55.077700Z

thank you for the heads up