Fork me on GitHub
#cursive
<
2018-12-11
>
jeremys15:12:47

Hey guys I am trying to start a repl from a deps.edn file. Any pointer on how to do it?

Alex Miller (Clojure team)15:12:24

Assuming you have the clojure tools installed, just clj

Alex Miller (Clojure team)15:12:38

oh, sorry didn’t realize we are in #cursive :)

Alex Miller (Clojure team)15:12:53

but you need the Cursive EAP with deps support

jeremys15:12:44

@alexmiller np! and I have the 1.8 release of cursive.

jeremys15:12:29

The thing is the “run with deps” option remains unclickable when I try to make a run config.

jeremys15:12:50

Right now i am thinking of trying this

jeremys15:12:59

I can create an alias in my deps.edn that will start a headless nrepl server, start that in a terminal then connect cursive via a remote repl config.

Alex Miller (Clojure team)15:12:20

not sure that’s going to help you with running with deps

Alex Miller (Clojure team)15:12:58

I’m sure there’s some other reason why it’s not working, but not sure what to suggest

jeremys15:12:39

It’s ok I am gonna tinker a bit. Thx Alex

shaun-mahood15:12:51

@jeremys: I had some issues using CLI tools, can you see if it works if you select "use tools.deps directly"? It fixed things for me when I had a similar problem.

jeremys16:12:20

@shaun-mahood I don’t where I could select this. My project was started using lein, I don’t know if that would prevent cursive from loading the CLI tools parts. When I try to “add framework support” deps isn’t there. Now when I try to create a configuration, I can create a “Clojure App”, a”Clojure Deps” or a “CLojure REPL local/remote” one. The support seems to be in Clojure App and Clojure repl local. In these two templates there is a “run with deps” choice with a field to select aliases. However I can’t select that option, it’s greyed out.

shaun-mahood16:12:11

@jeremys: As far as I understand it, you have to choose between lein and deps when importing your project - so you would need to change your project to use deps.edn and re-import it

jeremys16:12:26

@shaun-mahood Ok I’ll try that !

jeremys16:12:51

ok I re-imported my project after removing the .idea and the .iml file. I choose the deps support and I have now the option of running the repl from deps available! however I have a “Sync finish event has not been received” in the build widget of intellij, and I have an exception thrown when try to start the repl “Could not create shim”... I’ll try again later, gotta go for now. Thanks for the help.

cfleming22:12:28

@alexmiller Actually 1.8 is out and stable now with deps support.

cfleming22:12:14

No worries! Just so you know…

cfleming22:12:21

@jeremys So, right, glad you figured it out - you have to set your project up as a deps project for that to work. When you try it again let me know and we can look at those problems.