Jetbrains Tools: Difference between revisions
imported>Werner291 Created the page as a stub. |
23.05 is pretty old, so this note is no longer needed |
||
(8 intermediate revisions by 5 users not shown) | |||
Line 1: | Line 1: | ||
Various JetBrains IDEs and tools are available from nixpkgs under the `jetbrains`. For instance, CLion is available as the | Various JetBrains IDEs and tools are available from nixpkgs under the `jetbrains` namespace. For instance, CLion is available as the {{ic|jetbrains.clion}} package. | ||
== Plugins == | == Plugins == | ||
Some Jetbrains IDE plugins such as Github Copilot need to be patched in order to work on NixOS. | Some Jetbrains IDE plugins such as Github Copilot need to be patched in order to work on NixOS. | ||
For example, a package of CLion with the Github Copilot plugin pre-installed can be obtained by adding the following line to your package list: | For example, a package of CLion with the Github Copilot plugin pre-installed can be obtained by adding the following line to your package list: | ||
Line 13: | Line 11: | ||
where pkgs is a suitable version of nixpkgs. | where pkgs is a suitable version of nixpkgs. | ||
Note that Jetbrains IDEs tend to manage their configuration and plugins statefully. For example, if you have previously attempted to install Copilot through the IDE's plugin manager, you may need to delete the IDE's state in as described in [https://www.jetbrains.com/help/clion/uninstall.html# | Note that Jetbrains IDEs tend to manage their configuration and plugins statefully. For example, if you have previously attempted to install Copilot through the IDE's plugin manager, you may need to delete the IDE's state in as described in the [https://www.jetbrains.com/help/clion/uninstall.html#linux JetBrains documentation]. | ||
== JetBrains Toolbox == | |||
If you (understandably) want to eschew a fully-stateless JetBrains IDE setup, JetBrains Toolbox manages everything under {{ic|~/.local/share/JetBrains/Toolbox}} but currently (Jan. 2024) needs some tweaks to get working. | |||
<ol> | |||
<li>Install {{ic|pkgs.jetbrains-toolbox}} and launch it once</li> | |||
<li>Edit {{ic|~/.local/share/JetBrains/Toolbox/.storage.json}} to add the line {{ic|"preferredKeychain": "linux-fallback"}}</li> | |||
<li>Start to log-in normally, but stop after the JetBrains webpage opens</li> | |||
<li>Reopen JetBrains Toolbox, navigate to Settings, and click "Troubleshoot..."</li> | |||
<li>Follow the manual login flow as directed</li> | |||
</ol> | |||
After following these steps, JetBrains Toolbox will store user credentials in an encrypted (with a static key) file at {{ic|~/.local/share/JetBrains/Toolbox/.securestorage}}. If not followed, JetBrains Toolbox is unable to retrieve credentials via {{ic|libsecret}} (due to bwrap sandboxing?) and persistently notifies the user to re-authorize. | |||
It may also help to enable {{ic|nix-ld}} or launch through JetBrains Toolbox itself if the downloaded IDEs are unable to launch; see [https://github.com/NixOS/nixpkgs/issues/240444 nixpkgs#240444]. | |||
With the following configuration {{ic|rustrover}} was successfully started: | |||
programs.nix-ld.enable = true; | |||
programs.nix-ld.libraries = with pkgs; [ | |||
SDL | |||
SDL2 | |||
SDL2_image | |||
SDL2_mixer | |||
SDL2_ttf | |||
SDL_image | |||
SDL_mixer | |||
SDL_ttf | |||
alsa-lib | |||
at-spi2-atk | |||
at-spi2-core | |||
atk | |||
bzip2 | |||
cairo | |||
cups | |||
curlWithGnuTls | |||
dbus | |||
dbus-glib | |||
desktop-file-utils | |||
e2fsprogs | |||
expat | |||
flac | |||
fontconfig | |||
freeglut | |||
freetype | |||
fribidi | |||
fuse | |||
fuse3 | |||
gdk-pixbuf | |||
glew110 | |||
glib | |||
gmp | |||
gst_all_1.gst-plugins-base | |||
gst_all_1.gst-plugins-ugly | |||
gst_all_1.gstreamer | |||
gtk2 | |||
harfbuzz | |||
icu | |||
keyutils.lib | |||
libGL | |||
libGLU | |||
libappindicator-gtk2 | |||
libcaca | |||
libcanberra | |||
libcap | |||
libclang.lib | |||
libdbusmenu | |||
libdrm | |||
libgcrypt | |||
libgpg-error | |||
libidn | |||
libjack2 | |||
libjpeg | |||
libmikmod | |||
libogg | |||
libpng12 | |||
libpulseaudio | |||
librsvg | |||
libsamplerate | |||
libthai | |||
libtheora | |||
libtiff | |||
libudev0-shim | |||
libusb1 | |||
libuuid | |||
libvdpau | |||
libvorbis | |||
libvpx | |||
libxcrypt-legacy | |||
libxkbcommon | |||
libxml2 | |||
mesa | |||
nspr | |||
nss | |||
openssl | |||
p11-kit | |||
pango | |||
pixman | |||
python3 | |||
speex | |||
stdenv.cc.cc | |||
tbb | |||
udev | |||
vulkan-loader | |||
wayland | |||
xorg.libICE | |||
xorg.libSM | |||
xorg.libX11 | |||
xorg.libXScrnSaver | |||
xorg.libXcomposite | |||
xorg.libXcursor | |||
xorg.libXdamage | |||
xorg.libXext | |||
xorg.libXfixes | |||
xorg.libXft | |||
xorg.libXi | |||
xorg.libXinerama | |||
xorg.libXmu | |||
xorg.libXrandr | |||
xorg.libXrender | |||
xorg.libXt | |||
xorg.libXtst | |||
xorg.libXxf86vm | |||
xorg.libpciaccess | |||
xorg.libxcb | |||
xorg.xcbutil | |||
xorg.xcbutilimage | |||
xorg.xcbutilkeysyms | |||
xorg.xcbutilrenderutil | |||
xorg.xcbutilwm | |||
xorg.xkeyboardconfig | |||
xz | |||
zlib | |||
]; | |||
It could also be extended to the full list in {{ic|pkgs/build-support/appimage/default.nix}} | |||
[[Category:Applications]] |
Latest revision as of 05:03, 26 October 2024
Various JetBrains IDEs and tools are available from nixpkgs under the `jetbrains` namespace. For instance, CLion is available as the jetbrains.clion
package.
Plugins
Some Jetbrains IDE plugins such as Github Copilot need to be patched in order to work on NixOS.
For example, a package of CLion with the Github Copilot plugin pre-installed can be obtained by adding the following line to your package list:
(pkgs.jetbrains.plugins.addPlugins pkgs.jetbrains.clion ["github-copilot"])
where pkgs is a suitable version of nixpkgs.
Note that Jetbrains IDEs tend to manage their configuration and plugins statefully. For example, if you have previously attempted to install Copilot through the IDE's plugin manager, you may need to delete the IDE's state in as described in the JetBrains documentation.
JetBrains Toolbox
If you (understandably) want to eschew a fully-stateless JetBrains IDE setup, JetBrains Toolbox manages everything under ~/.local/share/JetBrains/Toolbox
but currently (Jan. 2024) needs some tweaks to get working.
- Install
pkgs.jetbrains-toolbox
and launch it once - Edit
~/.local/share/JetBrains/Toolbox/.storage.json
to add the line"preferredKeychain": "linux-fallback"
- Start to log-in normally, but stop after the JetBrains webpage opens
- Reopen JetBrains Toolbox, navigate to Settings, and click "Troubleshoot..."
- Follow the manual login flow as directed
After following these steps, JetBrains Toolbox will store user credentials in an encrypted (with a static key) file at ~/.local/share/JetBrains/Toolbox/.securestorage
. If not followed, JetBrains Toolbox is unable to retrieve credentials via libsecret
(due to bwrap sandboxing?) and persistently notifies the user to re-authorize.
It may also help to enable nix-ld
or launch through JetBrains Toolbox itself if the downloaded IDEs are unable to launch; see nixpkgs#240444.
With the following configuration rustrover
was successfully started:
programs.nix-ld.enable = true; programs.nix-ld.libraries = with pkgs; [ SDL SDL2 SDL2_image SDL2_mixer SDL2_ttf SDL_image SDL_mixer SDL_ttf alsa-lib at-spi2-atk at-spi2-core atk bzip2 cairo cups curlWithGnuTls dbus dbus-glib desktop-file-utils e2fsprogs expat flac fontconfig freeglut freetype fribidi fuse fuse3 gdk-pixbuf glew110 glib gmp gst_all_1.gst-plugins-base gst_all_1.gst-plugins-ugly gst_all_1.gstreamer gtk2 harfbuzz icu keyutils.lib libGL libGLU libappindicator-gtk2 libcaca libcanberra libcap libclang.lib libdbusmenu libdrm libgcrypt libgpg-error libidn libjack2 libjpeg libmikmod libogg libpng12 libpulseaudio librsvg libsamplerate libthai libtheora libtiff libudev0-shim libusb1 libuuid libvdpau libvorbis libvpx libxcrypt-legacy libxkbcommon libxml2 mesa nspr nss openssl p11-kit pango pixman python3 speex stdenv.cc.cc tbb udev vulkan-loader wayland xorg.libICE xorg.libSM xorg.libX11 xorg.libXScrnSaver xorg.libXcomposite xorg.libXcursor xorg.libXdamage xorg.libXext xorg.libXfixes xorg.libXft xorg.libXi xorg.libXinerama xorg.libXmu xorg.libXrandr xorg.libXrender xorg.libXt xorg.libXtst xorg.libXxf86vm xorg.libpciaccess xorg.libxcb xorg.xcbutil xorg.xcbutilimage xorg.xcbutilkeysyms xorg.xcbutilrenderutil xorg.xcbutilwm xorg.xkeyboardconfig xz zlib ];
It could also be extended to the full list in pkgs/build-support/appimage/default.nix