Search code examples
node.jsintellij-ideanpmfedora-29

How to fix Node interpreter can't been found by intellij, but the node file is in the folder


Intellij can't find my Node.js. If I add it locally the node file isn't visible, but in my file manager node is visible. How can I fix this?

node executable not found in $PATH

node & nodejs are both in the folder

Intellij can't find the file in the correct folder

node verions

I am on Fedora 29. I can run Node.js in my terminal, so I know it is there. Already tried to link the node file with the Node.js file in the terminal. I also tried to run node in visual studio code, but it seems not to work.

I installed node.js and npm with the following command:

 $ sudo dnf install npm nodejs

I expected that a re-installation and a reboot was going to fix it. But Intellij seems not to keep the node file invisible for me.


Solution

  • In my case running this command fixed the issue.

    ln -s "$(which node)" /usr/local/bin/node
    

    The problem is that I need to run this command anytime I Install a new Node version from NVM.