Skip to content

fix(windows+persona): dream MCP path POSIX-ify + generic persona seed — 0.24.6#19

Merged
Cain-Ish merged 2 commits into
mainfrom
fix/windows-dream-and-persona-seed
Jun 2, 2026
Merged

fix(windows+persona): dream MCP path POSIX-ify + generic persona seed — 0.24.6#19
Cain-Ish merged 2 commits into
mainfrom
fix/windows-dream-and-persona-seed

Conversation

@Cain-Ish

@Cain-Ish Cain-Ish commented Jun 2, 2026

Copy link
Copy Markdown
Owner

Two fixes from a Windows user's session

1. /second-brain:dream was broken on Windows (blocking)

dream.ts built the dream-snapshot.sh/dream-accept.sh path with Node path.join (backslashes on Windows: C:\Users\…) and handed it to bash, which ate the \ escapes → C:Users… → "No such file or directory". New toBashPath() converts to a Git-Bash POSIX path (/c/Users/…) before the spawn — fixes both the bash invocation and the scripts' own $(dirname "$0")/lib.sh resolution. MCP server → 2.6.2; 5 unit tests.

2. Persona-seed leaked the author's identity

The setup skill's persona-card scaffold shipped the plugin author's own conventions as the default persona (skill bodies under ~500 lines; extract templates to siblings, no patterns) and defaulted identity to senior engineer — leaking author content to every fresh install, and the setup/SKILL.md vs persona-context.sh seeds had diverged. Both seeds are now generic, neutral, and identical; identity defaults to a (set your role…) placeholder. New guard test.

Verification

Full suite green (the one intermittent test-lib-extractor-backend is a known ~5s-timeout flake — passes standalone, confirmed). Lockstep 0.24.6 / MCP 2.6.2; migration row added. Code/prompt/test-only — no state migration.

🤖 Generated with Claude Code

Cain-Ish and others added 2 commits June 3, 2026 00:12
…ard seed

1. Windows dream bug: dream.ts built the dream-snapshot.sh/dream-accept.sh path with
   Node path.join (backslashes on Windows: C:\Users\...) and passed it to bash, which
   ate the \ escapes -> 'No such file or directory', blocking /second-brain:dream on
   Windows. New toBashPath() converts to a Git-Bash POSIX path (/c/Users/...) before the
   spawn; also fixes the scripts' internal $(dirname $0)/lib.sh resolution. 5 unit tests.

2. Persona-seed leftover: the setup-skill persona-card template shipped the plugin
   AUTHOR's own conventions as the default persona ('skill bodies under ~500 lines;
   extract templates to siblings', 'no  patterns') and defaulted the identity
   to 'senior engineer' -- leaking author content to every fresh install, and the setup
   vs persona-context.sh seeds diverged. Both seeds are now generic, neutral, and aligned;
   identity defaults to a '(set your role…)' placeholder. New test-persona-card-seed.sh guard.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…P 2.6.2)

Version lockstep + migration row. Full suite green.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings June 2, 2026 22:23
@Cain-Ish Cain-Ish merged commit d78f24b into main Jun 2, 2026
1 check passed
@Cain-Ish Cain-Ish deleted the fix/windows-dream-and-persona-seed branch June 2, 2026 22:23

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR addresses two user-facing regressions: (1) /second-brain:dream failing on Windows due to backslash paths being passed to bash, and (2) persona-card scaffolding shipping author-specific defaults (including an asserted identity), with a new guard test to prevent recurrence. It also bumps the plugin and MCP server versions for the 0.24.6 release.

Changes:

  • Add toBashPath() and use it when invoking dream-snapshot.sh / dream-accept.sh to make Windows Git-Bash script paths work reliably.
  • Replace persona-card seed defaults in both the setup skill scaffold and persona-context.sh with neutral/generic text, plus add a regression guard shell test.
  • Bump versions and update the upgrade migration table entry for 0.24.6.

Reviewed changes

Copilot reviewed 9 out of 19 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
tests/test-persona-card-seed.sh Adds a guard test to prevent author-specific persona seed content and asserted identities from shipping.
skills/upgrade/SKILL.md Adds a 0.24.6 migration-table row describing the Windows dream fix + persona seed neutralization.
skills/setup/SKILL.md Updates the persona-card scaffold to be generic/neutral and removes author-specific conventions.
scripts/persona-context.sh Updates the auto-seeded persona-card template to be generic/neutral.
mcp/src/tools/dream.ts Introduces toBashPath() and uses it when spawning bash scripts to fix Windows path handling.
mcp/src/tools/dream.test.ts Adds Vitest coverage for toBashPath() path conversions.
mcp/src/server.ts Bumps MCP server version string to 2.6.2.
mcp/dist/tools/dream.test.js.map Built output for the new dream tool unit test (sourcemap).
mcp/dist/tools/dream.test.js Built output for the new dream tool unit test.
mcp/dist/tools/dream.test.d.ts.map Built output typings map for the new dream tool unit test.
mcp/dist/tools/dream.test.d.ts Built output typings for the new dream tool unit test.
mcp/dist/tools/dream.js.map Updates built sourcemap reflecting toBashPath() usage.
mcp/dist/tools/dream.js Updates built JS reflecting toBashPath() usage.
mcp/dist/tools/dream.d.ts.map Updates built typings map reflecting exported toBashPath().
mcp/dist/tools/dream.d.ts Updates built typings reflecting exported toBashPath().
mcp/dist/server.js Updates built MCP server version string to 2.6.2.
mcp/dist/server.bundle.js Updates bundled server output with toBashPath() and version bump.
.claude-plugin/plugin.json Bumps plugin version to 0.24.6.
.claude-plugin/marketplace.json Bumps marketplace version to 0.24.6.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 117 to +121
cat > "$PCARD_FILE" <<SEED
# Persona

## Identity
- ${ROLE:-senior engineer}
- ${ROLE:-(set your role in ~/.second-brain/USER.md)}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants