v1.2.3 release: remove ShoeGaze CLI scaffolding (ShoeGaze now standalone)
This commit is contained in:
@@ -0,0 +1,112 @@
|
||||
---
|
||||
name: lyrebird_release_prep
|
||||
description: Prepare the public LyrebirdRelease (mooo) repo from the Lyrebird dev repo, replacing the manual "export → hand-copy in Finder" step. Syncs the dev repo's committed tree into the release working tree, excluding maintainer-only paths that never ship (legacy/, PLAN.md, .claude/, .githooks/, .swiftpm/) and cleaning accumulated Finder duplicate cruft. Dry-run first, then apply, then guides commit + tag + push to mooo. Use when cutting a new Lyrebird release (e.g. bumping to a new vX.Y.Z tag).
|
||||
---
|
||||
|
||||
# Lyrebird Release Prep
|
||||
|
||||
Replicates the Lyrebird **dev** repo (`~/Documents/src/Lyrebird`, origin = bitbucket) into
|
||||
the public **release** repo (`~/Documents/src/LyrebirdRelease`, origin = `realizedsound.mooo.com`)
|
||||
that SwiftPM consumers resolve from — without the manual Finder export/hand-copy.
|
||||
|
||||
## What it does (and why it's safe)
|
||||
|
||||
Works from a clean `git archive HEAD` of the dev repo, so:
|
||||
- only **committed, tracked** files ship (no `.build`, no editor state),
|
||||
- accumulated Finder duplicate cruft (` 2`/` 3` suffixed dirs) never leaks in, and
|
||||
- the release's own `.git` and local `.build` are preserved.
|
||||
|
||||
Then it strips the maintainer-only paths that are tracked in dev but must **not** ship
|
||||
(verified to exactly account for the dev↔release tracked-file delta):
|
||||
|
||||
| Excluded | Why |
|
||||
|---|---|
|
||||
| `legacy/` | old pre-modernization reference code |
|
||||
| `PLAN.md` | private planning doc |
|
||||
| `.claude/` | agent working-copy mirror (release ships `claude/` installer source only) |
|
||||
| `.githooks/` | dev-only pre-commit hooks |
|
||||
| `.swiftpm/` | local Xcode package state |
|
||||
|
||||
The sync uses `rsync -a -c --delete` (checksum-based, so only real content differences
|
||||
transfer; `--delete` clears stale files + Finder cruft on the release side). A moo-URL guard
|
||||
on the release remote prevents `--apply` from ever touching the wrong directory.
|
||||
|
||||
`docs/` (including `00-working-order.md` / `01-completed-working-order.md`) **does** ship —
|
||||
only top-level `PLAN.md` is excluded from the planning material.
|
||||
|
||||
## Steps
|
||||
|
||||
### 1. Pre-flight
|
||||
|
||||
Confirm the dev repo has the release commit already made (the script archives `HEAD` — uncommitted changes do **not** ship):
|
||||
|
||||
```bash
|
||||
git -C ~/Documents/src/Lyrebird status --short # should be clean
|
||||
git -C ~/Documents/src/Lyrebird log -1 --oneline
|
||||
```
|
||||
|
||||
If dirty, commit first (or the maintainer may pass `--allow-dirty` to archive HEAD anyway).
|
||||
|
||||
### 2. Dry run
|
||||
|
||||
```bash
|
||||
~/.claude/skills/lyrebird_release_prep/prepare_release.sh
|
||||
```
|
||||
|
||||
Read the summary: it lists the excluded paths, the deletions (Finder cruft cleanup), and the
|
||||
**content changes** (should match exactly the files changed since the last release). Metadata-
|
||||
only (mtime/perms) churn is reported as a count and is git-invisible.
|
||||
|
||||
Stop and investigate if the content-change list contains anything unexpected.
|
||||
|
||||
### 3. Apply
|
||||
|
||||
```bash
|
||||
~/.claude/skills/lyrebird_release_prep/prepare_release.sh --apply
|
||||
```
|
||||
|
||||
This mirrors the dev tree into the release working tree. It prints the release repo's
|
||||
`git status --short` afterward — this is the authoritative content diff.
|
||||
|
||||
### 4. Commit, tag, push (maintainer runs — push needs your key/touch)
|
||||
|
||||
The script prints these; fill in the version and message:
|
||||
|
||||
```bash
|
||||
R=~/Documents/src/LyrebirdRelease
|
||||
git -C "$R" add -A
|
||||
git -C "$R" commit -m "vX.Y.Z release: <summary>"
|
||||
git -C "$R" tag -a vX.Y.Z -m "vX.Y.Z: <summary>"
|
||||
git -C "$R" push origin main && git -C "$R" push origin vX.Y.Z
|
||||
```
|
||||
|
||||
Verify the tag landed:
|
||||
|
||||
```bash
|
||||
git -C "$R" ls-remote --tags origin | grep vX.Y.Z
|
||||
```
|
||||
|
||||
### 5. Point consumers at the new tag
|
||||
|
||||
For a downstream package pinned to a local `swift package edit` override during development
|
||||
(e.g. ShoeGaze), drop the override and bump the dependency once the tag is live:
|
||||
|
||||
```bash
|
||||
cd <consumer-pkg>
|
||||
swift package unedit Lyrebird
|
||||
swift package update Lyrebird # resolves to the new tag if Package.swift `from:` allows it
|
||||
swift build && swift test
|
||||
```
|
||||
|
||||
## Flags
|
||||
|
||||
- `--dev PATH` / `--release PATH` — override the default repo locations.
|
||||
- `--apply` — actually modify the release working tree (default is dry-run).
|
||||
- `--allow-dirty` — proceed even if the dev repo has uncommitted changes (still archives HEAD).
|
||||
|
||||
## Maintaining the exclusion list
|
||||
|
||||
If a new maintainer-only top-level path is added to the dev repo, add it to the `EXCLUSIONS`
|
||||
array in `prepare_release.sh`. Sanity check: after a dry run, the release tracked-file count
|
||||
plus the excluded tracked-file counts should equal the dev tracked-file count
|
||||
(`git ls-files | wc -l` in each; `git ls-files <path> | wc -l` per exclusion).
|
||||
Reference in New Issue
Block a user