CHANGELOG
This commit is contained in:
parent
ac307708ba
commit
00b33dab4d
3 changed files with 13 additions and 2 deletions
|
|
@ -8,6 +8,11 @@ Babashka:
|
|||
|
||||
- Sort tasks in `bb tasks` output
|
||||
|
||||
Experimental:
|
||||
|
||||
- Add `bb run --parallel <task>`
|
||||
- Fix `:init` in `:tasks`
|
||||
|
||||
Deps.clj:
|
||||
|
||||
- Fix arg parsing when invoking from Powershell [#42](https://github.com/borkdude/deps.clj/issues/42)
|
||||
|
|
|
|||
|
|
@ -133,7 +133,7 @@
|
|||
task (get tasks task-name)]
|
||||
(if task
|
||||
(let [m? (map? task)
|
||||
init (and m? (get tasks :init))
|
||||
init (get tasks :init)
|
||||
prog (if-let [depends (when m? (:depends task))]
|
||||
(let [targets (target-order tasks task-name)]
|
||||
(loop [prog ""
|
||||
|
|
@ -154,7 +154,9 @@
|
|||
[[(format-task init prog)] nil])
|
||||
[(binding [*out* *err*]
|
||||
(println "No such task:" task-name)) 1])))))
|
||||
[[(format-task init (assemble-task-1 task-name task parallel? true))] nil])]
|
||||
[[(format-task
|
||||
init
|
||||
(assemble-task-1 task-name task parallel? true))] nil])]
|
||||
(when (= "true" (System/getenv "BABASHKA_DEV"))
|
||||
(println (ffirst prog)))
|
||||
prog)
|
||||
|
|
|
|||
|
|
@ -60,6 +60,10 @@
|
|||
(bb "foo")
|
||||
(is (= "quux\nbaz\nbar\nfoo\n" (slurp out)))))
|
||||
(fs/delete out)
|
||||
(testing "init test"
|
||||
(test-utils/with-config '{:tasks {:init (def x 1)
|
||||
foo x}}
|
||||
(is (= 1 (bb "foo")))))
|
||||
;; Note: this behavior with :when was complex, since the place where :when
|
||||
;; is inserted isn't very intuitive here
|
||||
;; This is why we don't support :when for now
|
||||
|
|
|
|||
Loading…
Reference in a new issue