Fork me on GitHub
#babashka
<
2021-05-22
>
bherrmann16:05:43

Is there a bb.edn file which lets me say "bb make-natives foo.clj" where foo.clj has "(defn main [] (println 88))" and generates native binaries for all the platforms?

borkdude16:05:03

This tutorial comes pretty close: https://github.com/borkdude/jayfu GraalVM doesn't allow cross compilation though

bherrmann03:05:31

Perhaps native binary is not what I need. I have something like 10 command line programs that I would like to deliver to my colleges who are on linux/osx/windows. For OSX and Linux, I can just deliver #!/usr/bin/env bb - assuming my windows devs are not using wsl, is there something similar for windows? or would they need to invoke

c:\> bb c:\scripts\ arg1
vs
$ stats arg1  # on Linux or OSX

borkdude06:05:28

The babashka book has a recipe for a .bat shebang. I can find the link for you when I’m back at a computer

borkdude06:05:05

You will need to create separate .bat scripts for those, but you can of course script that

borkdude06:05:56

An alternative, if the scripts are part of a project, is to use the new task runner

bherrmann02:05:57

cool, I did know http://command.com could do that - great.

borkdude16:05:55

Babashka SQL pods 0.0.8 - Now also available on Windows! - The Oracle and MySQL drivers are now available from the pod registry https://github.com/babashka/babashka-sql-pods https://github.com/babashka/pod-registry Babashka SQL pods let you access databases from babashka scripts via the next.jdbc API.