Repository navigation
The Mac path, a rehearsal that creates nothing, and what a failed scaffold leaves (#54) - #57
Conversation
…ffold leaves (#54) Brett Heap, 2026-09-05: "we have the case for windows only and wsl/linux users and mac users. we need to make sure it is explained for all. i think we have nothing so far for mac users" then "go, file the issue and pick it up after #49 lands". Read against main after #46 and #49, macOS was one line (`brew install gh`), nothing had ever run on a Mac, the `gh api` one-liner decoded with a flag BSD base64 does not take, and a first-time user could neither rehearse the run nor learn what a failure part-way leaves behind. README § Quick start: the platform block is now Linux / macOS / Windows, natively / Windows via WSL2. The macOS paragraph names where git, make and python3 come from (the Xcode Command Line Tools), that Homebrew is its own install (linked, not pasted) and prints the Apple Silicon PATH line, `brew install gh`, `brew install git-filter-repo` only for adopting, and that the stock /bin/bash 3.2 is enough because neither bash entry point uses newer syntax. `base64 -d` becomes `base64 --decode`. A "Rehearse first, creating nothing" paragraph documents `--local-remote-dir <dir>` and says exactly which route still touches the network (the command fetches setup.sh and setup.sh self-bootstraps; from a checkout nothing does) and that `--org` is only a string there. An "If it fails part-way" paragraph gives the creation order (spec, code, root last), that there is no rollback, the refusal of a second run, `--reuse-empty-repo` as root-only, `gh repo delete` and its scope, and `internal` as Enterprise Cloud only — each sentence checked against scaffold-project.py, shape_materialize.py and setup.sh. tests.yml gains a `tests-macos` job on macos-latest mirroring the Linux job (same action shas, same pins, same per-invocation identity), plus a step that prints /bin/bash --version and runs `/bin/bash -n` on setup.sh and on openRepoShape separately, because `bash -n a b` parses only `a`. Green on macos-latest is what "runs on a Mac" means here; there is no Mac on this side. Adversarial Opus review before opening found four defects, all fixed: the rehearsal paragraph claimed "no network" of a route that fetches setup.sh and clones the standard; the failure paragraph attributed the "NOTHING has been rolled back" line to any failure when only a failed push prints it, and described a clone-failure message that setup.sh prints only when the target already exists; the tests.yml comment claimed `bash -n` catches mapfile, declare -A and local -n, which are runtime builtins, not grammar; and the macOS prose asserted which bash the runner's /bin/bash is. README 872 -> 933, cap moved with the rationale beside it. AGENTS.md unchanged. 570 tests pass on Linux. Lane: xfactory-2 (xFactory-2) Co-Authored-By: Claude Fable 5.1 <[email protected]>
|
@codex review |
There was a problem hiding this comment.
Sorry @brettheap, you've used your own review budget of 250,000 diff characters for the last 7 days.
You can request another review in 16 hours and 2 minutes by commenting @sourcery-ai review. Upgrade to get a review now.
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Reviewer's GuideThis PR documents the complete macOS path, adds a macOS CI acceptance job, provides a local rehearsal mode explanation, and makes scaffold failure cleanup behavior explicit, with a portable Sequence diagram for the local scaffold rehearsalsequenceDiagram
actor User
participant openRepoShape
participant setup_sh as setup.sh
participant LocalRemotes as Local bare repositories
participant Project as Local project directory
User->>openRepoShape: openRepoShape Atlas --org org --local-remote-dir rehearsal
openRepoShape->>setup_sh: pass --local-remote-dir
setup_sh->>setup_sh: preflight and naming check
setup_sh->>User: print plan and Type yes to continue:
User->>setup_sh: yes
setup_sh->>LocalRemotes: clone and make bootstrap
setup_sh->>Project: create ./Atlas
Note over setup_sh,LocalRemotes: gh is never called, GitHub is not contacted
Flow diagram for scaffold creation order and partial failureflowchart TD
A[Preflight, naming check, and plan] --> B{Typed yes}
B -->|No| C[Nothing created]
B -->|Yes| D[gh repo create Project-spec]
D --> E[gh repo create Project-code]
E --> F[gh repo create Project]
F --> G[Seed and push spec and code]
G --> H[Build and push root]
H --> I[Set topic on all three repositories]
D -. failure .-> J[Created resources remain; no rollback]
E -. failure .-> J
F -. failure .-> J
G -. failure .-> J
H -. failure .-> J
I -. failure .-> J
File-Level Changes
Assessment against linked issues
Possibly linked issues
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
There was a problem hiding this comment.
🟡 Changes recommended
The new macOS quick-start text asserts Xcode Command Line Tools provide python3, which can mislead users because the tooling only requires python3 3.9+ to be present and may need a separate install.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
This PR improves first-time onboarding and cross-platform support by expanding the README for macOS, documenting an offline rehearsal mode and partial-failure cleanup, and adding a macOS CI job to validate behavior and bash syntax assumptions.
Changes:
- Expand README quick start to cover Linux/macOS/Windows separately, add
--local-remote-dirrehearsal guidance, and document partial-failure cleanup. - Update the
gh apione-liner to usebase64 --decodefor better cross-platform compatibility. - Add a
tests-macosGitHub Actions job and raise the README length hygiene cap accordingly.
File summaries
| File | Description |
|---|---|
| README.md | Adds macOS quick-start guidance, rehearsal mode documentation, failure cleanup notes, and updates the base64 decode spelling. |
| tests/test_repo_hygiene.py | Raises README length cap and records the rationale alongside existing hygiene conventions. |
| .github/workflows/tests.yml | Adds a macOS CI job that runs the suite and explicitly parses both bash entry points with /bin/bash. |
Review details
- Files reviewed: 3/3 changed files
- Comments generated: 1
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| Xcode Command Line Tools supply `git`, `make` and a `python3` — install them | ||
| with `xcode-select --install`, or type `git` once on a fresh Mac and the | ||
| installer offers itself; step 4 opens with a preflight that prints the | ||
| `python3` it found and refuses anything below 3.9. `gh` comes from Homebrew, |
There was a problem hiding this comment.
Taken, in 9cedaa4. The Tools do supply a python3 on current macOS, but older Tools shipped 3.8, which the preflight refuses, and the paragraph gave no exit. It now says: if the preflight refuses the one the Tools supplied, install a newer one from python.org or with brew install python, and the preflight finds it first on PATH. Cap 933 -> 936 for the reflowed paragraph.
Lane: xfactory-2 (xFactory-2)
…ilot on #57) Copilot's one finding on PR #57: the macOS paragraph read as claiming the Xcode Command Line Tools' python3 always suffices, while the preflight only requires a python3 of 3.9 or newer and points at python.org when it is missing. Older macOS Command Line Tools shipped 3.8, which the preflight refuses. One sentence names the exit: install a newer one from python.org or with `brew install python`, and the preflight finds it first on PATH. README 933 -> 936 (the paragraph reflowed); cap moved with the rationale. Lane: xfactory-2 (xFactory-2) Co-Authored-By: Claude Fable 5.1 <[email protected]>
There was a problem hiding this comment.
🟡 Changes recommended
The README’s updated base64 --decode one-liner is not compatible with macOS’s default base64 implementation and will fail for macOS users as written.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Review details
- Files reviewed: 3/3 changed files
- Comments generated: 1
- Review effort level: Lite
| ```sh | ||
| gh api repos/opensoft/openRepoShape/contents/setup.sh --jq .content \ | ||
| | base64 -d | bash -s -- --org <your-org> --project Atlas | ||
| | base64 --decode | bash -s -- --org <your-org> --project Atlas |
…counted 881 -> 945 #58 landed first and moved the README to 881 lines. This merge keeps its `.gitattributes` rows and rationale entry, and re-counts this branch's cap entry from 872 -> 936 to 881 -> 945 after it. The tree is identical to the branch rebased onto 0a84d6c, on which 583 tests passed; the ruleset refuses a force-push, so the rebase is carried as a merge. Lane: xfactory-2 (xFactory-2) Co-Authored-By: Claude Fable 5.1 <[email protected]>
|
There was a problem hiding this comment.
🟡 Changes recommended
The new README rehearsal section contains an inaccurate absolute claim about gh never being invoked when using openRepoShape, which should be corrected for consistency and user guidance accuracy.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Review details
- Files reviewed: 3/3 changed files
- Comments generated: 1
- Review effort level: Lite
| whole of that against three BARE repositories in `<dir>`: the same preflight | ||
| (where `gh` is neither required nor checked), the same naming check, the same | ||
| plan, the same `Type yes to continue:`, the same clone and `make bootstrap`. | ||
| `gh` is never called and nothing is created on GitHub. `--org` is still |
…5 cites the 34 pull requests merged since #343, section 6 drops the 13 known-limit issues that closed and adds the 63 checklist lines the five parents gained, section 7 lists the 12 open milestone issues, and the preflight sentence offers only what the preflight offers (#472) Refresh round 1 of the draft, against main d41cc29 (#402, merged 2026-10-13T21:17:39Z). GitHub was read between 21:23 and 21:43 UTC: the merged pull requests, the v1.0.0 milestone open and closed, every open issue, and the five tracking parents with their sub-issues, bodies and comments. Every merge commit of the 217 merged pull requests is on main. Section 5 places each of the 34 pull requests merged after #343 (2026-10-12T22:31:20Z) in its area, from its own body, one clause each; all 217 merged pull requests are now cited, with #16, #53 and #57 still in two areas. Three earlier sentences are made true of main: `check` has more verdicts than the four it named, and #465's docs and #505's accuracy pass show that `validate-pins.py` may ask `gh api` and that `openRepoShape --preflight` offers only `gh`, its login and its credential helper (`setup-project.py --preflight` also offers `git`). Section 6 lists the 47 open, unmilestoned sub-issues (it listed 60). It drops #189, #293, #303, #328, #386, #286, #259, #275, #322, #324, #338, #339 and #359, which closed. #389 is reworded now that #305's refusal has landed. #420 and the `a=b` line are narrowed to a hand-edited `adopt_branch:`, because an offline probe on d41cc29 shows #493's `plan-tracking-branch-missing` now stops a bad `tracking_branch:` at `check`, with no leg made, while `adopt_branch: "a..b"` still passes `check` and fails after both legs exist. The family annotated-tag line says `bump --to` now refuses one (#466). The 63 new lines are the parents' checklist lines posted or added since the first build, each checked against the code at d41cc29. Left out, and said so in the refresh record: docstring, comment and wording nits (as L2-7 was), lines that describe a branch not on main (#504's, #507's, #511's, #515's and #517's), lines filed into the milestone (#485, #514, #516), and three with no effect a person meets. Section 7 lists the 12 open milestone issues; 24 of the 30 it listed have closed. Lane 4's #510, #511, #512 and #513 have not landed, so #471, #499, #500, #501 and #502 stay open here and the Windows qualifier stays. Lane: openreposhape-4 (openRepoShape-4) Co-Authored-By: Claude Opus 5.5 <[email protected]>



Lane: xfactory-2 (xFactory-2)
Claim: #54 (claim in the issue body)
Closes #54.
What this changes
The Mac path, a rehearsal that creates nothing, and what a failed scaffold leaves. Brett Heap, 2026-09-05, in session: "we have the case for windows only and wsl/linux users and mac users. we need to make sure it is explained for all. i think we have nothing so far for mac users" → "go, file the issue and pick it up after #49 lands". Read against
mainafter #46 and #49: macOS was one line (brew install gh), nothing had ever run on a Mac, thegh apione-liner decoded withbase64 -d(a flag BSDbase64does not take), and a first-time user could neither rehearse the run nor learn what a failure part-way leaves behind.git,makeandpython3(xcode-select --install, or a baregiton a fresh Mac offers it; the preflight prints thepython3it found and refuses below 3.9); Homebrew is its own install — LINKED to brew.sh, not pasted — and its installer prints the Apple SiliconPATHline;brew install gh;brew install git-filter-repoonly for adopting; the stock/bin/bash3.2 is enough because neither bash entry point uses newer syntax (grepped for${x,,}${x^^}readarraymapfiledeclare -Alocal -n|&&>>;;&coproc: none), and zsh as the login shell changes nothing because both run underbashexplicitly.base64 -d→base64 --decodein thegh apione-liner; the only occurrence in the repository, no test asserted the old spelling.--local-remote-dir <dir>— same preflight (gh neither required nor checked), naming check, plan, typedyes, clone andmake bootstrap, against three bare repositories on disk;ghis never called and nothing is created on GitHub;--orgis still required but is only a string there, never checked against GitHub. The paragraph says exactly which route still touches the network: theopenRepoShapecommand fetchessetup.sh, andsetup.shself-bootstraps by cloning the standard;./setup.shfrom a checkout touches nothing. Verified by running it with aghshim that logs and exits: the log stayed empty.yes; creation order is<Project>-spec,<Project>-code,<Project>— the root LAST (scaffold-project.py,for role in ("spec", "code", "assembly")); there is NO rollback anywhere in the source; a failed push says so in the tool's own words; a second run is refused while the legs exist and there is no--force; the exits aregh repo delete(which needs thedelete_reposcope;gh repo delete --helpnamesgh auth refresh -s delete_repo) or a different--project;--reuse-empty-repocovers exactly a zero-commit ROOT and nothing else;internalis offered only by GitHub Enterprise Cloud organisations and refused by GitHub, not by this tool.tests-macosjob intests.ymlonmacos-latest, mirroring the Linux job: identical action shas,pytest==8.3.4andgit-filter-repo==2.47.0pinned identically, the same per-invocation git identity. One extra step prints/bin/bash --versionand runs/bin/bash -n setup.shand/bin/bash -n openRepoShapeSEPARATELY (bash -n a bparses onlya). The comment says what-ncan and cannot catch (grammar such as${x,,},|&,;;&,coproc; not a bash-4 builtin) and that the job cannot assert which bash/bin/bashis — it prints it. Green onmacos-latestis what "runs on a Mac" means here; there is no Mac on this side.AGENTS.mdunchanged (273 = cap). No script changes.Adversarial Opus review before opening found four defects, all fixed: the rehearsal paragraph claimed "no network" of a route that fetches
setup.shand clones the standard; the failure paragraph attributed the "NOTHING has been rolled back" line to any failure when only a failed push prints it (RULESET_HINT), and described a clone-failure message thatsetup.shprints only when the clone target already exists; thetests.ymlcomment claimedbash -ncatchesmapfile,declare -Aandlocal -n(runtime builtins, not grammar — proved by parsing a file that uses all three); and the macOS prose asserted which bash the runner's/bin/bashis. Plus trims: therepo_shape.pyinternals sentence, "delete the empty repositories" (a leg can hold commits after a partial failure) → "delete what was created".Not verifiable from this side, stated as such in the prose or hedged: every macOS-environment fact (Command Line Tools contents and version — CLT ships python3 3.9.6; the fresh-Mac
gitprompt; Homebrew's/opt/homebrewandshellenvline; that BSDbase64takes--decode— it certainly does not take-d; thatinternalneeds Enterprise Cloud). The bash half is settled by thetests-macosjob on this PR.Evidence
Linux:
python3 -m pytest tests -q— 583 passed on the tree at head2830d07(a merge ofmainat0a84d6c, #58, into the branch; the tree is byte-identical to the branch rebased onto that commit, which is where the run was made — the ruleset refuses a force-push, so the rebase is carried as a merge commit). Earlier heads: 570 on the branch before #56, 573 after it. Sequenced after #49 (#53: shared README platform paragraph, cap line andtests.yml) and after #58 (#51: shared cap line; this branch's cap entry now reads881 -> 945, after #51's872 -> 881). macOS: thetests-macosjob on this PR is the acceptance; on the first head it passed in 2m53s and its log shows the runner's/bin/bashisGNU bash, version 3.2.57(1)-release (arm64-apple-darwin25), under which both entry points parsed.Copilot's one review finding (the macOS paragraph implied the Command Line Tools' python3 always suffices; older Tools shipped 3.8) is folded in as one sentence naming the exit, cap 933 → 936 before the re-count.
Merge word: Brett Heap, 2026-09-05, "merge #54 on green too" — green including the macOS job.
🤖 Generated with Claude Code