Skip to content

DEV-1181: spell out reflect's safe symlink-to-copy steps - #3

Merged
tomaas merged 1 commit into
mainfrom
guillermo/dev-1181-reflect-copy
Oct 24, 2026
Merged

tomaas merged 1 commit into
mainfrom
guillermo/dev-1181-reflect-copy

Conversation

@tomaas

@tomaas tomaas commented Oct 24, 2026

Copy link
Copy Markdown
Owner

Follow-up to #2 for DEV-1181. Fixes the blind review's two should-fix items in skills/reflect/SKILL.md. Nothing else changes.

Changes

  • Safe copy procedure. "Replace the symlink with a copy" now has exact steps: readlink -f to find the real folder, copy its contents into a temp folder, rm the link with no -r and no trailing slash, mv the copy into place, and test ! -L before editing. The section warns that rm -r on the path with a trailing slash deletes files inside the shared checkout, and that plain cp -r copies the link. A project's .agents/skills/<skill> may be a plain folder (nothing to replace), and a copy there lives in the user's repo and must not be committed by accident.
  • Detached-copy notice. Before approval (step 5) and in the step 6 summary, the user is told that the copied skill no longer updates on git pull (install.sh prints skip <skill>), and that deleting the copy and rerunning install.sh restores it. "Blocks the next pull" now says the actual harm: the edit gets mixed into the shared checkout.
  • One CHANGELOG line under the 2026-10-24 section. No version or credit changes.

Verification

  • ./scripts/check-skill-names.sh prints ok: 55 skill names match their folders.
  • I ran the five steps in a scratch sandbox against a symlinked skill. The checkout's files were intact, the destination was a real folder, and rerunning install.sh printed skip foo (exists and is not a symlink).
  • The new text has no $ tokens, so Claude Code's skill text substitution can't rewrite it. The definition-of-done grep finds no Cursor terms.

🤖 Generated with Claude Code

Review follow-up to #2. reflect now gives the exact procedure for
replacing an installed skill symlink with a copy (readlink -f, copy to
a temp folder, rm the link with no trailing slash, mv, test ! -L),
covers project folders with no symlink and keeps them out of commits,
and tells the user the copy is detached from git pull and how to
restore it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@tomaas
tomaas merged commit 57075ef into main Oct 24, 2026
tomaas added a commit that referenced this pull request Oct 24, 2026
Second review follow-up to #3. The copy steps take a <dest>
placeholder for the global or project path, cover a project that has
no copy yet (copy from the global link and keep it), use mktemp -d
instead of a fixed temp path, refuse to mv onto an existing path, and
verify test -d, test ! -L and SKILL.md before editing.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
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.

1 participant