This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-01-30
Channels
- # babashka (19)
- # beginners (87)
- # calva (11)
- # cider (6)
- # cljdoc (30)
- # clojure (84)
- # clojure-china (1)
- # clojure-dev (13)
- # clojure-europe (4)
- # clojure-france (1)
- # clojure-gamedev (1)
- # clojurescript (12)
- # core-async (1)
- # cursive (12)
- # data-oriented-programming (1)
- # defnpodcast (1)
- # emacs (9)
- # events (1)
- # fulcro (8)
- # graalvm (1)
- # introduce-yourself (1)
- # missionary (6)
- # music (1)
- # nextjournal (14)
- # off-topic (26)
- # portal (2)
- # re-frame (1)
- # releases (2)
- # shadow-cljs (13)
Hello. Is there any way to write global tasks which can be run from any folder in the terminal?
yes, this is possible using --config ...
e.g.: foo
:
#!/usr/bin/env bash
bb --config ~/my_tasks/bb.edn [email protected]
and then:
foo tasks
foo my-task
This is exactly what i'm looking for. Thank you.
I use clj files to write bb scripts. How tell clj-kondo to ignore babashka namespaces which cannot be indexed ? Or how to tell Cursive to index babashka namespaces (e.g. babashka.tasks) ? See yellow (unknown symbols on picture?
I would be nice if we can attach somehow babashka source code into project to index and introspect babashka's namespaces
You can use bb print-deps
to print a deps.edn maps with deps, but the issue is that babashka.tasks
is not available yet as a JVM lib
For example I need to use spy function which was added recently in babashka. What I do: go to github, then use search to find which namespace contains spy, then add this namespace to :requires block.
but this is just example
how to work without indexing and introspection.
the timbre example should already work in cursive since this is in the output bb print-deps
BTW,
:deps {local/deps {:local/root "."}}
is a great feature. Now I can put all my tasks to clj files (from bb.edn) and debug them nicely.Cursive guide for babashka helped me. Thank you.