This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-11-03
Channels
- # beginners (167)
- # boot (22)
- # chestnut (3)
- # cider (9)
- # clojure (107)
- # clojure-berlin (1)
- # clojure-greece (3)
- # clojure-italy (6)
- # clojure-losangeles (6)
- # clojure-russia (8)
- # clojure-spec (71)
- # clojure-uk (42)
- # clojurescript (186)
- # community-development (1)
- # core-async (12)
- # core-typed (1)
- # css (15)
- # cursive (29)
- # data-science (11)
- # datomic (8)
- # defnpodcast (28)
- # duct (2)
- # fulcro (169)
- # graphql (6)
- # hoplon (3)
- # jobs-discuss (1)
- # kekkonen (5)
- # leiningen (11)
- # lumo (7)
- # off-topic (14)
- # om (1)
- # other-languages (14)
- # portkey (7)
- # re-frame (27)
- # reagent (14)
- # remote-jobs (1)
- # ring-swagger (5)
- # rum (15)
- # shadow-cljs (52)
- # spacemacs (59)
- # specter (78)
- # test-check (3)
- # vim (9)
- # yada (23)
@samuel.perrouault make-repl-connect-file
depends on @out-file
, which seems to be set only by the cljs-repl
task, and not cljs-repl-env
.
https://github.com/martinklepsch/boot-cljs-repl/blob/master/src/adzerk/boot_cljs_repl.clj#L110
@sinistral Actually cljs-repl-env does reset out-file to (io/file src "adzerk" "boot_cljs_repl.cljs").
In fact, if I cider-jack-in and then proceed to start a cljs repl from there it works fine
Actually saying this makes me realize I probably should discuss this with cider poeple rather than with boot poeple ^^
can someone help me to run boot-cljs from within (with-pre-wrap
block... something strange is happening
I've been trying to figure out why the hell it is taking so long to compile on our setup on incremental builds. And one of the things I wanted to do is to wrap a check around it so it would run only when .cljs and .cljc files change, otherwise it runs even when .scss files get modified.
Another thing I have noticed, every time it moves files from one temp folder to another folder, I don't know how to force it not to do that - because it's kinda of a bottleneck
The code inside with-pre-wrap
is run each time watch
runs, (cljs)
creates new Cljs compiler each time
So, don't call (cljs)
inside with-pre-wrap
Hmph, that is possible, but if the temp dirs are changing I don't know what else would cause that
This is my biggest problem with Boot.... Everything about boot is so cool and awesome, except when filesets get on the way - and everything just crumbles
If you want to control when cljs task is really run, based on the changed files, you need to build the middleware yourself instead of using with-pre-wrap
or maybe it could work with with-pre-wrap
but I'd recommend just writing the functions
Maybe something like this:
(deftask wrap-cljs []
(let [cljs-task (cljs :opts :here)]
(fn [next-handler]
(let [cljs-handler (cljs-task next-handler)]
(fn [fileset]
(if (cljs-files-changed? fileset)
(cljs-handler fileset)
(next-handler fileset)))))))
this will only create single cljs temp dirs per wrap-cljs
task etc.