nixpkgs/pkgs/applications/editors/jetbrains
2026-01-13 14:45:11 -05:00
..
builder jetbrains: reformat longDescriptions, adjust some wording 2026-01-09 17:30:08 +01:00
ides jetbrains: reformat longDescriptions, adjust some wording 2026-01-09 17:30:08 +01:00
patches jetbrains: update basic source dependencies and patches 2025-12-28 13:17:59 +01:00
plugins jetbrains: drop bundled plugins 2025-12-25 10:54:53 +01:00
source jetbrains.idea-oss: 2025.3.1 -> 2025.3.1.1 2026-01-09 01:21:50 +00:00
updater jetbrains: reimplement update scripts 2025-12-31 16:18:07 +01:00
default.nix jetbrains: split IDEs into separate nix files 2025-12-31 15:28:35 +01:00
readme.md treewide: fix typos 2026-01-13 14:45:11 -05:00

This directory contains the build expressions needed to build any of the JetBrains IDEs. The jdk is in pkgs/development/compilers/jetbrains-jdk.

Tests:

  • To test the build process of every IDE (as well as the process for adding plugins), build jetbrains.plugins.tests.empty.
  • To test that plugins are correctly stored in the plugins directory, build jetbrains.plugins.tests.stored-correctly.

How to use plugins:

  • Pass your IDE package and a list of plugin packages to jetbrains.plugins.addPlugins. E.g. pkgs.jetbrains.plugins.addPlugins pkgs.jetbrains.idea [ ideavim ]
  • The list has to contain drvs giving the directory contents of the plugin or a single .jar (executable).

Nixpkgs does not package JetBrains plugins, however you can use third-party sources, such as nix-jetbrains-plugins. Note that some plugins may not work without modification, if they are packaged in a way that is incompatible with NixOS. You can try installing such plugins from within the IDE instead.

Example derivations:

"Normal" plugin

fetchzip {
  url = "https://plugins.jetbrains.com/files/8607/786671/NixIDEA-0.4.0.18.zip";
  hash = "sha256-JShheBoOBiWM9HubMUJvBn4H3DnWykvqPyrmetaCZiM=";
}

"Single JAR file" plugin

fetchurl {
  executable = true;
  url = "https://plugins.jetbrains.com/files/7425/760442/WakaTime.jar";
  hash = "sha256-DobKZKokueqq0z75d2Fo3BD8mWX9+LpGdT9C7Eu2fHc=";
}

How to update IDEs:

  • Run ./updater/main.py. This will update binary and source IDEs. After this you can commit them.
    • See ./updater/main.py --help for additional flags.
    • The IDEs have passthru.updateScript set up to run ./updater/main.py. The script then uses the UPDATE_NIX_* environment variables as documented.

To keep things simple, the update script will search for the following markers and may replace any content between them:

  • update-script-start: urls / update-script-end: urls: URLs for binary IDEs
  • update-script-start: version / update-script-end: version: Version and build number for binary IDEs
  • update-script-start: source-args / update-script-end: source-args: Arguments for mkJetBrainsSource for source IDEs.

Any comments or other manual changes between these markers will be removed when the script runs.

How to add an IDE:

  • Add a new derivation in ides/
  • Add an entry to the URL templates in updater/updateInfo.json
  • Add it to default.nix

TODO:

  • drop the community IDEs
  • Switch mkJetBrainsProduct to use lib.extendMkDerivation, see also:
  • move PyCharm overrides to a common place outside of default.nix
  • package patchSharedLibs from default.nix as a hook
  • cleanup this TODO list, especially the following points, which have been here since 2023
  • replace libxcrypt-legacy with libxcrypt when supported
  • make jetbrains-remote-dev.patch cleaner
  • is extraLdPath needed for IDEA?
  • from source builds:
    • remove timestamps in output .jar of jps-bootstrap
    • automated update scripts
    • fetch .jars from stuff built in nixpkgs when available
      • what stuff built in nixpkgs provides .jars we care about?
        • kotlin
    • make configurePhase respect $NIX_BUILD_CORES
    • make the subdir of the resulting tar.gz always have a release number (2023.2.2) instead of a build number (232.9921.89)
  • jdk:
    • build on darwin
    • use chromium stuff built by nixpkgs for jcef?
    • make buildPhase respect $NIX_BUILD_CORES
    • automated update script?
  • on aarch64-linux:
    • from source build
    • see if build (binary or source) works without expat
  • on x86_64-darwin:
    • from source build
  • on aarch64-darwin:
    • from source build