Open marcomorain opened 6 years ago
My current work around is comment out :penantic? :abort
when loading a project in code
.
Another option could to be to start leiningen with a specific profile when starting from vscode.
Then I could add a custom setting in my ~/.lein
folder for this:
{:vscode {:pedantic :ranges}}
Hi @marcomorain and thank you for your recent contributions 👍
Could you point me out where do we set this option? I glanced through the code but haven't found any mentions of it. Is this option set by Leiningen implicitly?
We set this option on our projects in project.clj
This means that if our projects depend on any versions of nrepl or clj-fmt that are different from the versions that clojureVSCode injects, our projects fail to start.
I think I will make a PR to your README.clj with a description of the issue and how to fix it by editing ~/.lein/profiles.clj
👍
Oh, now I see :-)
This makes me think, that the right approach here is to provide a configuration option for passing arbitrary parameters for nREPL as we do for cljfmt
. What do you think?
If we invoke the repl with lein repl :headless :vscode
then users could put any special lein options that they would like into a :vscode
profile in ~/.lein/profiles.clj
As it stands, lein repl
uses the :repl
profile in ~/.lein/profiles.clj
In this case, let's invoke nREPL with :vscode
and add a section with the description of how to get an advantage of it to README.md. What do you think?
I'm running into this as well, and it appears the README update about how to work around it by editing ~/.lein/profiles.clj
never happened. Would you mind outlining that fix here?
At CircleCI we use
:pedentic? :abort
in most of our leiningen projects. This option prevents the leiningen from starting the repl unless there are no conflicting dependencies in the app.When clojureVSCode starts the repl, it adds additional dependencies to the app, which often causes the
:pedantic? :abort
checks to fail, and the repl fails to start.I suggest that we override the
penantic
flag set it to the default value,:ranges
when starting the repl from VSCode.Thoughts?