Repository navigation
Conversation
Contributor
|
Thanks for your pull request! Unfortunately, it doesn't meet the requirements for review:
Please update your PR to address the above. This PR will be automatically closed in 7 days if these requirements are not met. Full contribution requirements
|
When launching Visual Studio Code or derivative editors for a repository directory, inspect the repository root for a single .code-workspace file and launch that workspace file if present. Fall back to opening the directory when zero or multiple workspace files exist. Closes desktop#7007
1kailas
force-pushed
the
fix-test-for-invalid-chars-state
branch
from
October 2, 2026 18:12
872085f to
2668566
Compare
Contributor
|
Thank you for updating your pull request! It now meets the minimum requirements and has been queued for triage. |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #7007
Description
When opening a repository in Visual Studio Code (or derivative editors such as VSCodium, Cursor, Windsurf), users often organize their project settings, multi-root configurations, and recommended extensions in a
.code-workspacefile located at the repository root. Currently, GitHub Desktop always launches the editor passing the root repository folder, which causes VS Code to open as a standard folder rather than opening the workspace.This PR introduces workspace file detection during external editor launch:
Visual Studio Code,Visual Studio Code (Insiders),VSCodium,Cursor,Windsurf) and the target path is a directory:.code-workspace..code-workspacefile exists in the directory root, Desktop passes the path to that workspace file to the editor instead of the directory..code-workspacefiles exist (or if the target is a specific file, or if the editor is not VS Code), Desktop falls back to passing the original target path unchanged.app/test/unit/launch-editor-test.tscovering single, multiple, hidden, directory-named, non-existent, file-target, and non-VS Code editor scenarios.Screenshots
N/A (editor launch integration change, no UI styling changes)
Release notes
Notes: [Improved] Open repository in Visual Studio Code using the root .code-workspace file when present