Repository navigation
feat: install via Scoop and Homebrew straight from this repo - #8
Merged
Merged
Conversation
A Scoop manifest (scoop/ccswitch.json) installable by raw URL with no bucket, and a Homebrew formula (Formula/ccswitch.rb) that makes the repo itself a tap. Both pin the same hashes the release publishes; packaging/update-manifests.sh is their single source of shape, and a new release.yml job regenerates and commits them whenever a version tag ships. A binary that a package manager installed is that manager's to update, so ccswitch upgrade now detects Scoop/Homebrew install layouts and defers with the right command — and the update nudge names that command too.
Review follow-ups: hashes are now looked up in SHA256SUMS by asset name and validated as full SHA-256s, so a missing or renamed asset fails the release instead of committing an empty hash; the manifest commit lives in the release job (one runner, one hash pass), refuses to downgrade what main serves when an old tag is re-run, and rebases-and-retries instead of dying non-fast-forward; a tag that doesn't match the compiled version constant fails the build before anything publishes. managedInstaller is anchored to this app's own directory (no more locking out anyone with a folder named cellar), honours relocated Scoop roots via SCOOP/SCOOP_GLOBAL, and shares one selfPath() resolver with the nudge so the two can't disagree; the nudge computes the hint lazily, keeping the common up-to-date exit path free of symlink walks. Both generated files now say what generates them.
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.
What
scoop/ccswitch.json, installable by raw URL with no bucket needed —scoop install https://raw.githubusercontent.com/NotAProgrammer187/claude-code-profiles/main/scoop/ccswitch.json;scoop update ccswitchhandles updates, and theautoupdateblock keeps any bucket that copies the manifest in step.Formula/ccswitch.rbmakes this repo itself a tap —brew tap notaprogrammer187/ccswitch <repo URL>thenbrew install notaprogrammer187/ccswitch/ccswitch. Picks the right binary for Apple Silicon / Intel macOS / Linux.packaging/update-manifests.sh; a newmanifestsjob in release.yml regenerates them from the just-published assets and commits to main on every version tag, so they can never lag a release.ccswitch upgradedefers to the owning manager: a binary living underscoop/apps/or a HomebrewCellar/is refused with the right command (scoop update ccswitch/brew upgrade ccswitch), and the update nudge names that command instead ofccswitch upgrade.Notes
🤖 Generated with Claude Code