Skip to content

fix: make palette, preview, and MCP setup match the CLI - #317

Merged
SebTardif merged 4 commits into
mainfrom
fix/usability-298-316
Oct 22, 2026
Merged

SebTardif merged 4 commits into
mainfrom
fix/usability-298-316

Conversation

@SebTardif

@SebTardif SebTardif commented Oct 22, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Command palette entries stay available in a new folder and when the status bar is hidden. The extension activates on startup and still detects the CLI.
  • The status bar opens Show Status. The full report is in the Output channel. Update asks before it downloads.
  • Workspace MCP files store command as patchloom. A stale path is rewritten. Windsurf may keep the resolved path. The native server follows patchloom.mcpSurface. Writing .vscode/mcp.json warns that it adds a second server.
  • Windows patchloom.cmd and patchloom.bat launch through cmd.exe /d /s /c.
  • Quick Action preview runs in the workspace so format config and EditorConfig match Apply. The preview copy and any backup session it created are removed. Content fields keep newlines. The preview document is patchloom-preview, not an untitled buffer.
  • Batch Apply opens commented examples, dry-runs, then asks before writing. Patch apply and merge do the same, from a file or the clipboard. A preview that would change files exits 2 with ok: true and applied: false. That result still reaches the write confirmation. The write itself still requires exit 0. A conflicting merge preview (exit 8) stops and does not offer Apply. Allow conflict markers still previews as exit 2 and can be written.
  • Undo can target the latest backup, a session, or a path. Search hits open from a list. Setup Workspace asks for the folder once and always ends with a summary. Verify MCP uses the workspace and the configured command.

Closes #298
Closes #299
Closes #300
Closes #301
Closes #302
Closes #303
Closes #304
Closes #305
Closes #306
Closes #307
Closes #308
Closes #309
Closes #310
Closes #311
Closes #312
Closes #313
Closes #314
Closes #315
Closes #316

Test plan

Commands stay available in a new folder and when the status bar is hidden.
The status bar opens Show Status, and the full report goes to the Output
channel. Workspace MCP entries use the command name patchloom. The native
server follows the core or full setting. Windows npm shims launch through
cmd.exe. Quick Action and batch previews run in the workspace and ask
before writing. Undo can target a session or a path, and search hits open
from a list.

Closes #298
Closes #299
Closes #300
Closes #301
Closes #302
Closes #303
Closes #304
Closes #305
Closes #306
Closes #307
Closes #308
Closes #309
Closes #310
Closes #311
Closes #312
Closes #313
Closes #314
Closes #315
Closes #316

Signed-off-by: Sebastien Tardif <sebtardif@ncf.ca>
github-actions[bot]
github-actions Bot previously approved these changes Oct 22, 2026
Comment thread src/binary/launch.ts
// `/s` strips one leading quote and the last quote. Callers that set
// windowsVerbatimArguments must supply that pair. A host that quotes
// argv itself (native MCP) must not get a second pair.
const commandLine = verbatim ? `"${script}"` : script;
Comment thread src/binary/launch.ts
Comment on lines +55 to +60
const result = await execFileAsync(launch.file, launch.args, {
...options,
encoding: "utf8",
shell: launch.shell,
windowsVerbatimArguments: launch.windowsVerbatimArguments
});
A blank comSpec falls through to the real COMSPEC path on Windows CI.

Signed-off-by: Sebastien Tardif <sebtardif@ncf.ca>
github-actions[bot]
github-actions Bot previously approved these changes Oct 22, 2026
Batch Apply, Patch Apply, and Patch Merge treated every non-zero
preview as a failure. The CLI exits 2 with ok true and applied false
when that preview would change files, so the write confirmation never
appeared. Exit 2 is accepted only on the dry run. A real --apply still
requires exit 0, and patch merge exit 8 stays a conflict.

Probed with patchloom 0.37.1. npm run check: 504 tests, 92.95% lines.

Signed-off-by: Sebastien Tardif <sebtardif@ncf.ca>
github-actions[bot]
github-actions Bot previously approved these changes Oct 22, 2026
A three-way merge that conflicts exits 8 and does not write, with or
without --apply. The preview warned and then still asked to Apply, and
confirming reported that the merge completed. Exit 8 now stops after
the warning. Allow conflict markers still previews as exit 2 and can
be written.

Probed with patchloom 0.37.1. npm run check: 505 tests, 92.97% lines.

Signed-off-by: Sebastien Tardif <sebtardif@ncf.ca>
@SebTardif
SebTardif marked this pull request as ready for review October 22, 2026 20:06
@SebTardif
SebTardif merged commit 303909a into main Oct 22, 2026
24 of 25 checks passed
@SebTardif
SebTardif deleted the fix/usability-298-316 branch October 22, 2026 20:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment