gtache / intellij-lsp

Plugin adding Language Server Protocol support for IntelliJ
Apache License 2.0
397 stars 48 forks source link

Does not work with nvm managed node #157

Open dsame opened 3 years ago

dsame commented 3 years ago

WebStorm, node installed with nvm, osx.

I see the vague message to "check settings"

image

the only settings related to nodejs is:

image

and it is ok.

nixel2007 commented 3 years ago

try to start idea from terminal

dsame commented 3 years ago

try to start idea from terminal

@nixel2007 it works. Do you think i should stay with this workaround or there's some setting in the preferences?

nixel2007 commented 3 years ago

@dsame you should pass full path to node executable in LSP settings, if you use nvm-managed node. nvm adds path to node executable into your PATH env variable in your terminal settings (.profile, .bashrc, etc...). When you start IntelliJ IDEA from command pallete it doesn't know about PATH overriding cause terminal settings are not applied. but if you start IDEA from terminal it grabs overrided PATH from terminal.