Skip to content

fix: recache preserves file modes - #16

Merged
grams merged 1 commit into
mainfrom
fix/recache-preserve-mode
Oct 21, 2026
Merged

grams merged 1 commit into
mainfrom
fix/recache-preserve-mode

Conversation

@grams

@grams grams commented Oct 21, 2026

Copy link
Copy Markdown
Contributor

undev and repair recached every file as 0644 (internal/cache/recache.go), dropping the executable bit on plugin scripts. A script invoked directly (e.g. scripts/pr-state.sh of a skill) then exits 126 « Permission denied »; hooks went unnoticed because they run through bash <script>. The copy now keeps the source mode, removing any stale destination file first so a read-only file doesn't block a re-copy.

New E2E test: dev → undev keeps a 0755 script executable (fails without the fix).

🤖 Generated with Claude Code

https://claude.ai/code/session_016sNiMarQfbcHRWLuevWarY

`undev` and `repair` recached every file as 0644, dropping the executable bit
on plugin scripts: a script called directly then exits 126. The copy now keeps
the source file's permissions.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016sNiMarQfbcHRWLuevWarY
@grams grams self-assigned this Oct 21, 2026
@grams
grams merged commit 3ee00a1 into main Oct 21, 2026
1 check passed
@grams
grams deleted the fix/recache-preserve-mode branch October 21, 2026 09:32
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