JetBrains IDEs support for `nix-shell` w/ `nix-idea` plugin: Per-project environment

The current way to support nix-shell in the JetBrains suite of IDEs is by using the nix-idea plugin (GitHub).

However, it’s currently not possible to modify the environment per-project (instead of globally for the IDE instance) in any of the JetBrains IDEs. The environment that is inherited from the shell is used for every project window in the IDE, and any changes to that environment will be inherited by every project window within that IDE.

There is a GitHub issue for nix-idea to solve this problem:
NixOS/nix-idea: #1 Add support for nix-shell in JetBrains products

Which references an issue for IntelliJ IDEA that would enable per-project environments, that would enable per-project nix-shell instances:
IDEA-288756: Common extension point for environment variables

Please vote for this YouTrack issue with your JetBrains account to ensure it gets prioritized.

List of JetBrains IDEs:

  • IntelliJ IDEA
  • PyCharm
  • WebStorm
  • PhpStorm
  • RubyMine
  • CLion
  • GoLand
  • Rider
  • DataGrip
  • AppCode