Skip to content

fix(init): create a junction for .agents/skills on Windows and report link failures honestly - #263

Open
ophiocus wants to merge 1 commit into
theam:mainfrom
ophiocus:fix/windows-skills-junction
Open

fix(init): create a junction for .agents/skills on Windows and report link failures honestly#263
ophiocus wants to merge 1 commit into
theam:mainfrom
ophiocus:fix/windows-skills-junction

Conversation

@ophiocus

@ophiocus ophiocus commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

Closes #230 — credit to @Julian-Genuario for the precise report: EPERM on Windows without Developer Mode, blamed on "filesystem without symlink support." Claimed in-thread with right of way offered; the courtesy window has passed, so here is the fix, verified on the reporting platform.

The fix

  • Directory junctions need no privileges on Windows, so on EPERM/EINVAL init now falls back to one (absolute target — the ok line says so honestly: "junction — absolute; recreate after moving the repo") instead of failing.
  • When even the junction fails, the warn names the two real remedies — Developer Mode, or an elevated shell — instead of misdiagnosing the filesystem.
  • Every other platform keeps the original relative symlink path, byte-identical.

Found underneath (masked until now)

The init end-to-end test also spawned Biome through its POSIX .bin shim, which spawnSync cannot execute on Windows (status null) — invisible before because the symlink death always came first. It now runs Biome's JS entry through node, same behavior everywhere.

Verified

init.test.mjs: 8/8 on Windows 11 — the first time that file has ever passed there — and 8/8 on Linux, unchanged.

Interplay with #245, stated plainly: that PR's verify-windows CI job currently skips the init e2e naming this issue as its unskip criterion. Once both land, a one-line follow-up removes the skip and the whole init flow is guarded on windows-latest forever. Happy to push that follow-up the moment the second of the two merges.

… link failures honestly

On Windows without Developer Mode the skills symlink fails with EPERM and
init blamed "filesystem without symlink support" - the wrong cause and no
remedy (theam#230). Directory junctions need no privileges, so init now falls
back to one (absolute target, said out loud in the ok line) and, when even
that fails, names the two real fixes. The init end-to-end test also
spawned Biome through its POSIX .bin shim, which spawnSync cannot execute
on Windows (status null) - masked until now because the symlink death came
first; it now runs Biome's JS entry through node. init.test.mjs: 8/8 on
Windows for the first time, 8/8 on Linux unchanged.

Closes theam#230

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@ophiocus
ophiocus force-pushed the fix/windows-skills-junction branch from d1eefbc to dad6500 Compare September 3, 2026 18:25
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.

init misreports the failed .agents/skills symlink on Windows (EPERM, not a filesystem limitation); a junction would work

1 participant