amazon-workspaces: Add context menu entry & URL protocol handler#17980
amazon-workspaces: Add context menu entry & URL protocol handler#17980FilipDeVos wants to merge 1 commit into
Conversation
Add support to create the workspace uri handler for amazon-workspaces post install and remove it post uninstall.
📝 WalkthroughWalkthroughThe PR updates Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
bucket/amazon-workspaces.json (1)
1-68: ⚡ Quick winTesting instructions for this manifest.
Before merging, please test the manifest locally:
Optional: Enable debug mode and set GitHub token (for checkver to access GitHub API for releases):
scoop config debug true scoop config gh_token <your-github-token> # Read access onlyForce version detection and autoupdate:
.\bin\checkver.ps1 -App amazon-workspaces -fAuto-format (Lint) the JSON manifest:
.\bin\formatjson.ps1 -App amazon-workspacesTest installation (including URL handler registration):
scoop install .\bucket\amazon-workspaces.jsonVerify URL handler was registered correctly:
Get-Item -LiteralPath 'HKCU:\Software\Classes\workspaces\shell\open\command' | Get-ItemPropertyTest uninstallation (including URL handler cleanup):
scoop uninstall amazon-workspacesVerify URL handler was removed:
Test-Path 'HKCU:\Software\Classes\workspaces' # Should return FalseFor more details, see the Contribution Guide.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@bucket/amazon-workspaces.json` around lines 1 - 68, The reviewer provided manual testing steps to validate this manifest — run checkver and autoupdate, format the JSON, install the manifest, verify the URL protocol registration and removal, and confirm the pre_install/post_install/post_uninstall registry logic works as expected; specifically execute .\bin\checkver.ps1 -App amazon-workspaces -f, .\bin\formatjson.ps1 -App amazon-workspaces, scoop install .\bucket\amazon-workspaces.json, inspect HKCU:\Software\Classes\workspaces\shell\open\command to confirm the command set by post_install (uses workspaces.exe and the 'workspaces' scheme), then scoop uninstall amazon-workspaces and ensure the post_uninstall logic removed HKCU:\Software\Classes\workspaces when the value matches the expected string.Source: Coding guidelines
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@bucket/amazon-workspaces.json`:
- Around line 1-68: The reviewer provided manual testing steps to validate this
manifest — run checkver and autoupdate, format the JSON, install the manifest,
verify the URL protocol registration and removal, and confirm the
pre_install/post_install/post_uninstall registry logic works as expected;
specifically execute .\bin\checkver.ps1 -App amazon-workspaces -f,
.\bin\formatjson.ps1 -App amazon-workspaces, scoop install
.\bucket\amazon-workspaces.json, inspect
HKCU:\Software\Classes\workspaces\shell\open\command to confirm the command set
by post_install (uses workspaces.exe and the 'workspaces' scheme), then scoop
uninstall amazon-workspaces and ensure the post_uninstall logic removed
HKCU:\Software\Classes\workspaces when the value matches the expected string.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 4398946e-3c5f-49ea-8193-20de3a2b38b6
📒 Files selected for processing (1)
bucket/amazon-workspaces.json
|
/verify |
|
All changes look good. Wait for review from human collaborators. amazon-workspaces
|
z-Fng
left a comment
There was a problem hiding this comment.
Please update the manifest based on the existing one, e.g., #17728, with the following changes:
- Use a
.regfile instead of executing PowerShell commands within the manifest to add registry keys. - Make it optional so that users can manually run the
reg import xxx.regcommand to apply it themselves. - Adapt for global installation: The registry keys should be written to
HKLM (HKEY_LOCAL_MACHINE)instead ofHKCU (HKEY_CURRENT_USER)when a global installation is performed.
Add support to create the workspace uri handler for amazon-workspaces post install and remove it post uninstall.
Closes #17913
<manifest-name[@version]|chore>: <general summary of the pull request>