refactor: extract ShortcutLaunchExecutor#4
Conversation
Move launch orchestration and terminal argument building into Core so CmdPal commands and the Run plugin share one implementation. Co-authored-by: Cursor <cursoragent@cursor.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 292a2e0f28
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
Pull request overview
This PR refactors workspace/shortcut launching by extracting shared launch orchestration into ShortcutLaunchExecutor and terminal command-line construction into TerminalLauncherArgs, and adds a small helper for opening a workspace dev-server link post-launch. It also introduces initial unit tests for the new helpers.
Changes:
- Added
ShortcutLaunchExecutor+ShortcutLaunchResult/Optionsto centralize workspace/launch-entry execution and post-launch behavior. - Added
TerminalLauncherArgsto consolidate PowerShell/WSL/CMD argument construction and escaping helpers. - Added
WorkspaceDevServerActionsplus unit tests forTerminalLauncherArgsandShortcutLaunchExecutorerror paths.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| QuickShell.Core/Services/WorkspaceDevServerActions.cs | Adds a small helper for deciding whether to open / attempting to open a workspace dev-server link. |
| QuickShell.Core/Services/TerminalLauncherArgs.cs | Introduces shared escaping and argument builders for PowerShell/WSL/CMD/WT launch strings. |
| QuickShell.Core/Services/ShortcutLaunchExecutor.cs | Adds the new central launch orchestrator and post-launch warning aggregation. |
| QuickShell.Core.Tests/TerminalLauncherArgsTests.cs | Adds unit tests for argument escaping/building behavior. |
| QuickShell.Core.Tests/ShortcutLaunchExecutorTests.cs | Adds unit tests for basic launch precondition failures (missing directory / no enabled entries). |
Honor RunAsAdmin/RunAsStandard in multi-launch workspaces, normalize directories before existence checks, and fix cmd.exe nested quoting. Co-authored-by: Cursor <cursoragent@cursor.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c6f6c25a04
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Reuse TerminalLauncherArgs for cmd.exe and Windows Terminal cmd suffixes so quoting stays consistent with the fixed cd /d path pattern. Co-authored-by: Cursor <cursoragent@cursor.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: bedb3a2d96
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Double trailing backslashes in WT quoted args, parse WSL distro from profile command line before display name, and gate dev-server auto-open behind OpenDevServerOnLaunch (defaults off). Co-authored-by: Cursor <cursoragent@cursor.com>
Wire the dev-server auto-open opt-in through the shortcut form, draft persistence, save path, and validation. Co-authored-by: Cursor <cursoragent@cursor.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 9ae2caceb0
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
LaunchEntry now forces IncludeDevServerLink false so context-menu entry launches do not open the browser when OpenDevServerOnLaunch is enabled. Co-authored-by: Cursor <cursoragent@cursor.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a2ed500f29
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Summary
Merge note
Merge before other feature PRs — origin/master references TerminalLauncherArgs without the file.
Test plan