This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-08-30
Channels
- # adventofcode (4)
- # aleph (1)
- # announcements (6)
- # babashka (11)
- # beginners (63)
- # calva (73)
- # clj-kondo (9)
- # clj-on-windows (20)
- # cljdoc (8)
- # cljsrn (4)
- # clojure (48)
- # clojure-europe (20)
- # clojure-italy (1)
- # clojure-nl (11)
- # clojure-spec (11)
- # clojure-uk (3)
- # clojurescript (32)
- # cloverage (1)
- # conjure (1)
- # cryogen (5)
- # datomic (83)
- # fulcro (28)
- # graphql (23)
- # gratitude (4)
- # helix (15)
- # honeysql (4)
- # improve-getting-started (14)
- # introduce-yourself (3)
- # jackdaw (5)
- # kaocha (11)
- # leiningen (1)
- # malli (1)
- # meander (5)
- # off-topic (18)
- # pathom (17)
- # pedestal (6)
- # polylith (15)
- # practicalli (1)
- # quil (2)
- # reitit (4)
- # releases (6)
- # shadow-cljs (38)
- # sql (20)
- # testing (6)
- # timbre (5)
- # tools-deps (11)
- # vim (2)
Hi guys, is it possible to use a REPL with the bb.edn file? I mean some expressions obviously can be used, but I can’t eval the whole file for example. It is not a big deal as bb starts fast.
Hmm I saw this: https://book.babashka.org/#_repl_2
is the key part that it starts within a task, rather than the whole file? it should be fine as usually I’m working at one task at a time 🙂
Tasks are always running in some context, eg as a dependency of some other task, so the ability to start a REPL at any point is useful there. The alternative is to start a REPL yourself and then invoke your tasks with run
Thanks, will try it out. I was just used to opening the file in emacs and evaling the whole thing but it makes sense now
If you'd like to be able to pull up a socket repl on the result of any task e.g. bb foo bar
-> bb repl foo bar
, https://github.com/cldwalker/bb-clis/blob/98052ae55e360dda00da310def6981f2dc2bcd1a/src/cldwalker/bb_clis/babashka/task.clj#L30-L40 does this nicely
is there a recommended way to check for the platform in babashka e.g. if you’re running on linux or macOS? I have´ bb -e "(defn macos? [] (-> (babashka.process/\$ uname) deref :out slurp (clojure.string/includes? \"Darwin\"))) (macos?)"
right now but wondering if there’s something better.