Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

boot-cljs-repl pollutes project directory #32

Open
domkm opened this issue Nov 1, 2015 · 4 comments
Open

boot-cljs-repl pollutes project directory #32

domkm opened this issue Nov 1, 2015 · 4 comments
Labels

Comments

@domkm
Copy link

domkm commented Nov 1, 2015

boot-cljs-repl is polluting my project directory by compiling to "out/" instead of "target/*".

(deftask dev []
  (comp
   (watch :verbose true)
   (speak)
   (reload :asset-path "public"
           :on-jsload 'my.project/restart!)
   (cljs-repl)
   (cljs :optimization :none
         :source-map true
         :compiler-options {:verbose true})
   (repl :server true)))

When I connect to the nREPL server and type (start-repl) to start the CLJS REPL, an "out/" directory is created.

@martinklepsch
Copy link
Contributor

Thanks for the report @domkm. I can reproduce this with 0.2.0.

I assume it might be an issue with weasel?

@pandeiro
Copy link
Contributor

pandeiro commented Nov 2, 2015

I think Weasel exposes what's necessary but boot-cljs-repl does not try to set :output-dir and doesn't expose it as a task option :output-dir to pass on, either.

I am working on a fix for this locally and would be glad to contribute the change back. I'll test it and report back soon.

EDIT: I think I may be wrong about Weasel. It exposes this function, used by boot-cljs-repl: https://github.com/tomjakubowski/weasel/blob/master/src/clj/weasel/repl/websocket.clj#L32-L38. I've tried to use it to pass in an :output-dir option here: pandeiro@a7a5d5f . Still when I try using this updated version and specifying :output-dir in cljs-repl, the out dir is still created.

@Deraen
Copy link
Contributor

Deraen commented Jul 12, 2016

I tried setting output-dir to Boot-cljs tmp-dir which I think would be the correct value, but didn't have success. The repl kept creating out dir.

https://github.com/adzerk-oss/boot-cljs-repl/compare/repl-output-dir?expand=1

Also related #16, #22

@gtrak
Copy link

gtrak commented Jul 1, 2017

seems like for now on 0.4.0-SNAPSHOT, this works:

(task-options!
  start-repl {:cljs-repl-opts {:output-dir "target/public/main.out"}})

Thanks to @Deraen for this relevant commit: 04b6f44

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants