wip [skip ci]
This commit is contained in:
parent
60e25043d4
commit
644634be1d
3 changed files with 5 additions and 5 deletions
|
|
@ -708,7 +708,8 @@ Use -- to separate script command line args from bb command line args.
|
||||||
:preloads preloads
|
:preloads preloads
|
||||||
:loader (:loader @cp/cp-state)}))))
|
:loader (:loader @cp/cp-state)}))))
|
||||||
exec-fn (exec-fn)
|
exec-fn (exec-fn)
|
||||||
exec-src [(sci/binding [sci/file (or @sci/file "<task: >")]
|
exec-src [(sci/binding [sci/file (or @sci/file "<task>")
|
||||||
|
core/command-line-args command-line-args]
|
||||||
(sci/eval-string* sci-ctx exec-src))
|
(sci/eval-string* sci-ctx exec-src))
|
||||||
0]
|
0]
|
||||||
clojure [nil (if-let [proc (deps/clojure command-line-args)]
|
clojure [nil (if-let [proc (deps/clojure command-line-args)]
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,6 @@
|
||||||
[clojure.string :as str]))
|
[clojure.string :as str]))
|
||||||
|
|
||||||
(defn bash [& args]
|
(defn bash [& args]
|
||||||
;; (prn :args args)
|
|
||||||
;; (prn :cmd *command-line-args*)
|
;; (prn :cmd *command-line-args*)
|
||||||
(-> (p/process ["bash" "-c" (str/join " " args)]
|
(-> (p/process ["bash" "-c" (str/join " " args)]
|
||||||
{:inherit true})
|
{:inherit true})
|
||||||
|
|
|
||||||
|
|
@ -7,8 +7,8 @@
|
||||||
:args [-e (apply + (map (fn [i]
|
:args [-e (apply + (map (fn [i]
|
||||||
(Integer/parseInt i))
|
(Integer/parseInt i))
|
||||||
*command-line-args*))]}
|
*command-line-args*))]}
|
||||||
:tree {:task/type :babashka
|
:describe {:task/type :babashka
|
||||||
:args [:clojure -Stree]}
|
:args [:clojure -Sdescribe]}
|
||||||
:do-bash {:task/type :babashka
|
:do-bash {:task/type :babashka
|
||||||
:args [:do :bash "ls | wc -l"
|
:args [:do :bash "ls | wc -l"
|
||||||
:__ :eval-plus 1 2 3]}
|
:__ :eval-plus 1 2 3]}
|
||||||
|
|
@ -16,4 +16,4 @@
|
||||||
:args [:do :count-files
|
:args [:do :count-files
|
||||||
:__ :bash "ls | wc -l"
|
:__ :bash "ls | wc -l"
|
||||||
:__ :eval-plus 1 2 3
|
:__ :eval-plus 1 2 3
|
||||||
:__ :tree]}}}
|
:__ :describe]}}}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue