This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-08-25
Channels
- # aws (1)
- # bangalore-clj (1)
- # beginners (15)
- # boot (4)
- # clara (7)
- # cljs-dev (7)
- # cljs-experience (3)
- # cljsrn (1)
- # clojure (143)
- # clojure-austin (2)
- # clojure-germany (1)
- # clojure-italy (11)
- # clojure-serbia (11)
- # clojure-spec (96)
- # clojure-uk (20)
- # clojurescript (70)
- # community-development (58)
- # cursive (14)
- # data-science (1)
- # datomic (45)
- # events (2)
- # fulcro (19)
- # jobs (5)
- # jobs-rus (2)
- # off-topic (40)
- # om (24)
- # onyx (3)
- # parinfer (52)
- # pedestal (6)
- # protorepl (38)
- # re-frame (15)
- # reagent (11)
- # ring-swagger (5)
- # specter (37)
- # sql (3)
- # unrepl (3)
- # vim (1)
Why is the following task not writting a file in my '/target' folder?
(deftask create-file
[]
(let [tmp-main (core/tmp-dir!)]
(fn middleware [next-handler]
(fn handler [fileset]
(core/empty-dir! tmp-main)
(let [out (io/file tmp-main "some_file.txt")]
(util/info "Creating a file %s ... \n" (.getPath out)) ;; /Users/nha/.boot/cache/tmp/ ... /10sx/-skza10/some_file.txt
(spit out "CONTENT !"))
(-> fileset
(core/add-source tmp-main)
core/commit!
next-handler)))))
I call it from the repl:
(boot (create-file) (target))
@nha source files are not included in the output: https://github.com/boot-clj/boot/wiki/Filesets#fileset-components