Jetbrains Tools: Difference between revisions

imported>Werner291
Fixed wrong link subheading
imported>Magneticflux-
Add section on JetBrains Toolbox and workarounds
Line 14: Line 14:


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].
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].