This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-08-31
Channels
- # announcements (6)
- # babashka (32)
- # beginners (78)
- # biff (11)
- # calva (7)
- # clj-kondo (20)
- # clojure (35)
- # clojure-europe (10)
- # clojure-nl (4)
- # clojure-norway (8)
- # clojure-uk (2)
- # clojurescript (41)
- # conjure (14)
- # core-async (10)
- # cursive (7)
- # datomic (12)
- # deps-new (4)
- # emacs (15)
- # fulcro (48)
- # gratitude (11)
- # hugsql (1)
- # hyperfiddle (3)
- # introduce-yourself (3)
- # jobs (3)
- # klipse (2)
- # off-topic (7)
- # polylith (30)
- # reitit (1)
- # remote-jobs (1)
- # reveal (8)
- # scittle (4)
- # shadow-cljs (40)
- # squint (13)
- # tools-deps (7)
- # xtdb (7)
one thing I'd often want to have is a flag in bb tasks to not execute dependent tasks. I'd find that useful when interactively working on a script. Do other folks feel that need as well?
@mkvlr I think you could just put the task code in a .clj
file (which is recommended anyway when your task code grows beyond a couple of lines)
hmm, think I'd still find it useful to not execute deps, especially when using bb to automate just simple shell invocations
that works but probably not convenient enough to actually make me do it as opposed to waiting the extra time…
yep, bb build:static-app
https://github.com/nextjournal/clerk/blob/main/bb.edn#L38
I think there is a maybe a better solution here: to make :release-js not do anything if there's nothing new to build. https://blog.michielborkent.nl/speeding-up-builds-fs-modified-since.html
but when developing it locally and I ran it once I don't want to re-run it all the time
if there was an easy way to get a hash for a tree skipping extra work might become a lot easier & reliable
tbh I think the least amount of effort is to just comment out :depends and then turn it back on
I suppose your long running task(s) that you want to typically skip during dev could simply check if it should run? Maybe check an env var? Or an option on the command line? Or is that still too clumsy?
I'm interested in having the deps declared via :depends
and skipping those. Over lunch I came to the conclusions that declaring them in an external file and manually invoking them via bb -x
is fine I guess. I guess adding a flag for this isn't easy either as it would conflict with the args of the task?
maybe following on the same topic: how would I quickly test some task from command line before it lands as value to a :task
key in bb.edn
but retaining the same context, say :paths
and :deps
of the bb.edn
?
Are you asking: how do I test a dependency? Do you mean, print the result of a dependent task? You can run it with:
bb run --prn dependent-task