Fork me on GitHub
#cider
<
2018-10-09
>
Michael Fiano04:10:06

Can I have cider auto-require and switch ns when I jack-in with clojure-cli like it does for lein?

bozhidar09:10:40

@mfiano Not sure what you mean by this. There’s no functionality apart from the jack-in that’s build-tool specific.

dominicm10:10:56

@bozhidar maybe the init ns of Leiningen?

bozhidar13:10:11

Ah, got it.

bozhidar13:10:27

Yeah, that’s lein specific indeed. I guess think we need to pass some namespace be evaluated in the command-line string for the cli-tools. @mfiano If that’s what you meant - please, file a ticket with CIDER.

bozhidar13:10:29

@dominicm Btw, we can also add an initial ns to nREPL itself. I recall I discussed this idea with Chas back in the day. I never liked that the best approach we had was to just evaluate some (in-ns after we connected. (I think this can some param we send clone for instance).

bozhidar13:10:45

(but that being said - doing something with the command-line would certainly be easier)

Michael Fiano14:10:19

@bozhidar Well I have a deps.edn alias {:dev {:main-opts ["-e" "(require,'[mfiano.crawler.core,:as,crawler]),(in-ns,'mfiano.crawler.core)"]}} and set cider-clojure-cli-global-options to "-A:dev", but for some reason only the code is required and the ns stays at user, unlike running clj from a shell.

dominicm16:10:29

@mfiano that won't have an effect on nrep l think