Skip to content

Conversation

@ComradeVanti
Copy link

@ComradeVanti ComradeVanti commented Oct 13, 2025

This PR implements functionality to open the current repository in an external editor. Below are the main changes:

  1. Added setting for configuring external editor path
  2. Add quick action for opening repo with editor
  3. Add global menu action for opening repo with editor
  4. Add CTRL+SHIFT+A shortcut for opening the repo

Screencast_20251013_151754

Things that could still be added:

  • Validate that the entered path is actually a code editor
  • Better error handling if no valid editor was specified. Currently, when I enter some random string like not an editor into the editor, it will still be saved and only fails once it tries to actually run that command. We then get an ugly error notification with some low-level error details. Would be nice to hide those
  • Per-project overrides for the editor setting

A few notes:

  • This is my first time contributing to this repo, so I was not sure what the best place to put things was. Please let me know if there are any corrections
  • I broke the changes into a few small commits, which can be squashed if that is preferred

This PR partially resolves #230

This change adds a quick-action for opening the current repo in editor. Right now, it is hardcoded to open it in VSCodium, since that is what I have installed, but the next change should make it configurable.
This change adds a setting/preference for the external editor to open all projects with. This change does not yet add per-project editor settings. The setting is also not used anywhere yet.
We now use the editor configured through the app settings to open the repo
We now display an error notification when no editor was set.
The check for whether the editor setting is set was done at the usage site in RepositoryOpenViewModel until now. But this logic could be relevant in other places as well. This change moves it into a new property on the AppSettingsRepository
Previously we used the Kotlin navtive API for starting the process for opening the repo in an external editor. But I just discovered the IShellManager service and assume that it is better to use this. So this change refactores to use that service.
There is now a keybind for opening the repo in an external editor. For now it is set to CTRL+SHIFT+A to match GitHub Desktop
Until now the logic for opening the current repository using an external editor was hosted in the RepositoryOpenViewModel. I noticed that the logic for opening the repo in terminal was hosted in its own use-case object, so this change also introduces such an object for the open-in-editor action
This change adds a global menu button for opening the repo in the configured external editor.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Open in editor button

1 participant