INFO

Workarounds

https://youtrack.jetbrains.com/projects/IJPL/issues/IJPL-1055/Load-interactive-shell-environment-variables-on-Linux

Workaround 1 (broken on macOS, see Experiment):

launchctl setenv PATH "/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:$HOME/.cargo/bin"

Given that it doesn’t respect /etc/paths, configuring /etc/paths.d doesn’t work either.

Workaround 2 (working):

Start the application from a shell:

alias idea='open "/Applications/IntelliJ IDEA CE.app"'
idea

- Workaround 2 worked for me. This step is essential to verify that nvm, node.js (or any tool that brought you to this issue) are running as expected.

To run IDE / PhpStorm from Terminal, could be as simple as typing in the terminal:

phpstorm

or the name of your IDE, like webstorm

Workaround 3 (official fix for Linux):

Starting from 2025.3, it is possible to enable shell variable loading on Linux by adding -Dij.load.shell.env=true to VM options (Help | Edit custom VM options) and restarting the IDE.

Please give it a try, but ensure first that your shell RC file is not interactive (i.e., doesn’t stop on a prompt) and does not perform long operations. Check for INTELLIJ_ENVIRONMENT_READER environment variable if necessary.

Workaround 4 (broken):

Set PATH variable in Path Variables settings.

Experiment

$ # start from Finder
$ ps auxeww | grep /idea | grep -o ' PATH=[^ ]*'
 PATH=/usr/bin:/bin:/usr/sbin:/sbin
$ ps auxeww | grep .GradleDaemon | grep -o ' PATH=[^ ]*' # inherits idea's PATH
 PATH=/usr/bin:/bin:/usr/sbin:/sbin
 
$ launchctl setenv PATH \
  "/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:$HOME/.cargo/bin" # doesn't affect `idea`
$ ps auxeww | grep /idea | grep -o ' PATH=[^ ]*'
 PATH=/usr/bin:/bin:/usr/sbin:/sbin