fix: preserve exec bit on dist/cli.js after build - #610
Merged
Colin Francis (colifran) merged 6 commits intoAug 8, 2026
Merged
Conversation
The prebuild clean removes dist/, and tsc regenerates cli.js without the executable bit. This breaks a globally linked install (npm link), since the bin symlink then points at a non-executable file: `openwiki` fails with "permission denied" after every rebuild. Add a postbuild chmod so the linked global command survives rebuilds. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
🦋 Changeset detectedLatest commit: 5296c15 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Colin Francis (colifran)
approved these changes
Aug 8, 2026
Colin Francis (colifran)
left a comment
Collaborator
There was a problem hiding this comment.
Thanks Tomas Bel (@Tomaskobel)! In the future please make sure you add a changeset using pnpm changeset
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
prebuildremovesdist/, andtscregeneratescli.jswithout the executable bit. For a globally linked install (npm link), thebinsymlink then points at a non-executable file, soopenwikifails withpermission deniedafter every rebuild. Contributors hit this on each edit → build → run iteration.Adding a
postbuildstep restores the bit.Before
After
Checks
pnpm run format:check— all files match Prettierpnpm run lint:check— cleanpnpm test— 935 passed (76 files)Note on changesets
No changeset included: this affects the local build only, not published runtime behavior, since npm sets the exec bit on
binentries at install time. Happy to add one if you'd prefer.🤖 Generated with Claude Code