Skip to content

[Visual Studio Code] Fix Opening Workspaces on Windows - #29797

Merged
raycastbot merged 3 commits into
raycast:mainfrom
KamilDev:fix/vscode-windows-workspace
Aug 19, 2026
Merged

raycastbot merged 3 commits into
raycast:mainfrom
KamilDev:fix/vscode-windows-workspace

Conversation

@KamilDev

Copy link
Copy Markdown
Contributor

Description

Fixes opening .code-workspace entries on Windows.

In LocalItem, the open action passed the file:// URI to the editor for workspace entries on Windows, while folder and file entries were opened by path. The VS Code CLI treats positional arguments as paths (code.exe [options] [paths...]; URIs need --file-uri / --folder-uri), so the URI resolved to a non-existent relative path and VS Code opened an empty untitled editor in the already-open window instead of the workspace.

This is a leftover from #28072: the revert in #28913 restored open(path, editorApp) only in the else branch, so workspace entries kept opening through the URI. This restores the pre-#28072 line:

open(isWin ? path : props.uri, editorApp);

Validation

  • Verified in development mode on Windows 11 with VS Code 1.127.0: a multi-root .code-workspace picked from Search Recent Projects used to open as a new empty file, and now opens as the workspace. Reverting the diff reproduces the old behavior.
  • npm run lint
  • npm run build

Checklist

  • I read the extension guidelines
  • I read the documentation about publishing
  • I ran npm run build and npm run lint; the change itself was verified in Raycast in development mode
  • I checked that files in the assets folder are used by the extension itself
  • I checked that assets used in the README are located outside the metadata folder if they were not generated with our metadata tool

Windows passed the file:// URI of .code-workspace entries as a positional
argument to the editor, and the VS Code CLI treats positional arguments as
paths. VS Code therefore opened an empty untitled file instead of the
workspace. Open all local entries by path on Windows, completing the revert
in raycast#28913.
@raycastbot raycastbot added extension fix / improvement Label for PRs with extension's fix improvements extension: visual-studio-code-recent-projects Issues related to the visual-studio-code-recent-projects extension platform: macOS platform: Windows labels Jul 28, 2026
@raycastbot

raycastbot commented Jul 28, 2026 •

Copy link
Copy Markdown
Collaborator

Thank you for your contribution! 🎉

🔔 @thomaspaulmann @iainsimmons @macbookandrew @cy-98 @immint023 @vimtor @tonka3000 @aka-rabbi-inv @oilbeater @QIanGua @hakob8956 @erics118 @tmwrnr @tleo19 @aeither @yug2005 @VatsalSy @Tarocch1 @list-jonas @xilopaint @lacherogwu @Nenuial @robertocinetto @ecntu @raxityo @yusifaliyevpro @jkker @sillasHead @MuhammadrizoDeveloper you might want to have a look.

You can use this guide to learn how to check out the Pull Request locally in order to test it.

📋 Quick checkout commands
BRANCH="fix/vscode-windows-workspace"
FORK_URL="https://github.com/KamilDev/extensions.git"
EXTENSION_NAME="visual-studio-code-recent-projects"
REPO_NAME="extensions"

git clone -n --depth=1 --filter=tree:0 -b $BRANCH $FORK_URL
cd $REPO_NAME
git sparse-checkout set --no-cone "extensions/$EXTENSION_NAME"
git checkout
cd "extensions/$EXTENSION_NAME"
npm install && npm run dev

We're currently experiencing a high volume of incoming requests. As a result, the initial review may take up to 15 business days.

@greptile-apps

greptile-apps Bot commented Jul 28, 2026 •

Copy link
Copy Markdown
Contributor

Greptile Summary

The PR fixes Windows workspace opening by passing the local filesystem path to the editor and updates extension metadata.

  • Uses the local path for all Windows local entries, including .code-workspace files.
  • Adds the contributor to the extension manifest.
  • Documents the Windows workspace fix in the changelog.

Confidence Score: 5/5

The PR appears safe to merge.

No blocking failure remains.

Important Files Changed

Filename Overview
extensions/visual-studio-code-recent-projects/src/index.tsx Simplifies local-item opening so Windows consistently passes a filesystem path while other platforms retain URI behavior.
extensions/visual-studio-code-recent-projects/package.json Adds KamilDev to the extension contributor list.
extensions/visual-studio-code-recent-projects/CHANGELOG.md Adds release notes describing the corrected Windows workspace-opening behavior.

Reviews (3): Last reviewed commit: "Update CHANGELOG.md" | Re-trigger Greptile

@raycastbot raycastbot added the OP is contributor The OP of the PR is a contributor of the extension label Aug 18, 2026

@0xdhrv 0xdhrv left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, approved ✅

@raycastbot
raycastbot merged commit cd75ae8 into raycast:main Aug 19, 2026
2 checks passed
@github-actions

Copy link
Copy Markdown
Contributor

@raycastbot

Copy link
Copy Markdown
Collaborator

🎉 🎉 🎉

Such a great contribution deserves a reward, but unfortunately we couldn't find your Raycast account based on your GitHub username (@KamilDev).

Please link your GitHub account to your Raycast account to receive your credits and soon be able to exchange them for some swag.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

extension fix / improvement Label for PRs with extension's fix improvements extension: visual-studio-code-recent-projects Issues related to the visual-studio-code-recent-projects extension OP is contributor The OP of the PR is a contributor of the extension platform: macOS platform: Windows

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants