Uh oh!
There was an error while loading. Please reload this page.
chore: consolidate local-install flow into a single shell script - #688
Conversation
Moves the pack + install + chmod + Tower-restart sequence into scripts/local-install.sh so the root package.json script stays a one-liner. The script: - Packs both @cluesmith/codev-core and @cluesmith/codev tarballs into their package directories (clearing stale tarballs first so the install glob matches exactly one file) - Uninstalls the global packages first (npm install -g over an existing same-version install is sometimes a silent no-op) - Installs both tarballs together - Restores +x on scripts/forge (pnpm pack strips the executable bit, which otherwise surfaces as "GitHub CLI unavailable" in the sidebar) - Restarts Tower so the running process picks up the new code CLAUDE.md and AGENTS.md updated to point at the new script and drop the now-redundant multi-step instructions.
waleedkadous
commented
Apr 22, 2026
Excellent consolidation — turning the four-step dance into one Worth flagging: this overlaps intentionally with #696 — that PR fixes the Two tiny nits, neither blocking:
Feel free to merge — both points are follow-ups at most. |
waleedkadous
left a comment
There was a problem hiding this comment.
Approved — nits above are soft suggestions, not merge blockers.
Playwright strict mode rejected the card locators because the feature shipped in PR #695 renders review-blocking sentences that mention the other member's name (e.g. Waleed's card contains "Amr is waiting for you to review #688"), so hasText: 'Amr' / 'Waleed' matched both cards. Use filter({ has: '.team-member-github' }) with an anchored regex on the @handle instead — handles are unique per card and not duplicated in any review-blocking text.
Uh oh!
There was an error while loading. Please reload this page.
- Switch shebang from #!/bin/sh to #!/usr/bin/env bash to match
neighbor scripts (install-hooks.sh, run-tests.sh, etc.) and
guard against future bashisms breaking on dash-based /bin/sh.
- Replace `chmod -R +x scripts/forge` with a `find ... -name '*.sh'
-exec chmod +x {} +` so only shell scripts get the executable
bit if non-script files ever land in scripts/forge/.
Both were soft suggestions from waleedkadous on PR cluesmith#688; functional
behavior is unchanged today.
Summary
Moves the pack + install + chmod + Tower-restart sequence into
scripts/local-install.shso the rootpackage.jsonscript stays a one-liner. Primary use case: iterating on the Codev CLI (porch, afx, Tower, forge) during local dev. Also enables end-to-end testing of extension ↔ Tower features.Why
The previous multi-step flow (
pnpm build→ twopnpm packs →pnpm local-install→afx tower stop && afx tower start) had three latent bugs I hit during PR #682 testing:pnpm --filter <pkg> packwrites to the repo root, not the package directory.local-install's glob (./packages/codev/cluesmith-codev-*.tgz) picked up leftover tarballs from prior runs instead of the fresh one. I was testing old code without realizing it. Script now uses--pack-destinationandrm -fstale tarballs upfront.npm install -g <same-version.tgz>over an existing install often does nothing visible. Fresh code never replaced the old install. Script uninstalls explicitly before reinstalling.pnpm packstrips the executable bit fromscripts/forge/**/*.sh. Withoutchmod +xafter install,overview.ts'sspawn('scripts/forge/github/pr-list.sh')hits permission-denied, surfacing as "GitHub CLI unavailable — could not fetch PRs" in the extension. Script restores+xas part of install.Plus ergonomics: one command instead of four, harder to forget the Tower restart.
Changes
scripts/local-install.sh— pack (to package dirs), uninstall globals, install fresh, chmod forge scripts,afx tower stop && afx tower startpackage.json:local-installscript reduced toscripts/local-install.shCLAUDE.mdandAGENTS.md: Local Build Testing section simplified topnpm build+pnpm -w run local-install, bullet list rewritten to describe what the script doesScope
.vsixreload handles thatnpm install -g @cluesmith/codev)Test plan
pnpm -w run local-installfrom a clean state — confirms install succeeds, Tower restarts, version reports correctlychmod +xstep, running the installedscripts/forge/github/pr-list.shdirectly fails with "permission denied"; after, it returns[]Out of scope
pnpm publish --filtersequence, not this scriptvsce publish)