Repository navigation
docs(contributing): make your own fork the PR base, and unbreak the gotmp teardown fixture - #3
Merged
Merged
Conversation
…the PR base The documented setup points local `origin` at the parent and hands the fork to `no-mistakes` as a push target only, so every PR it opens has the parent as its base repo. GitHub then holds a fork PR's workflow runs at `action_required` until someone with write access on the parent approves them, and until that happens neither `CI` nor `Require no-mistakes` reports at all, so the author cannot judge the PR green. That is the right trade when you are contributing a change back, but it is the wrong one when you are running firstmate as your own fleet. Document the second shape: `origin` is your fork, the parent stays reachable as `upstream`, and `gh repo set-default` pins the base repo that `gh pr create` would otherwise default to the fork's parent. It has to be configuration rather than a per-run flag, because `no-mistakes` opens PRs against `origin` and exposes no per-run base override. With `origin` already the fork, `--fork-url` becomes unnecessary. Also record the consequence for `/updatefirstmate`: `bin/fm-update.sh` fast-forwards from the remote literally named `origin`, so it tracks the fork after this change, and the parent has to be merged in deliberately from `upstream` once your fork's `main` has diverged.
`fm-teardown.sh` began sourcing `bin/fm-busy-lib.sh` for the shared
per-harness busy contract, but neither fake-root builder in this suite
symlinks that sibling into its `bin/`, so the real teardown subprocess
aborts on the missing source and every assertion that expects a zero exit
fails:
bin/fm-teardown.sh: line 172: .../bin/fm-busy-lib.sh: No such file or directory
not ok - teardown exited non-zero with a valid tasktmp
This is the failure currently red on `main` in the `Behavior portable
serial 1` shard. It is a fixture gap only - a real home always has the
sibling - so the fix is the same one-line symlink the other required
siblings already get, added to both builders.
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
Two changes:
CONTRIBUTING.mdgains a "Running your own line from a fork" section documenting how to make your own fork the PR base instead of the parent, and why that has to be remote configuration rather than a per-run flag.tests/fm-gotmp.test.shsymlinksbin/fm-busy-lib.shinto both fake-root builders. This is the failure currently red onmainin theBehavior portable serial 1shard.Why
The documented setup (step 1 + step 3) points local
originat the parent and hands the fork tono-mistakesas a push target only, so every PR it opens has the parent as its base repo. GitHub then holds a fork PR's workflow runs ataction_requireduntil someone with write access on the parent approves them. Until that happens neitherCInorRequire no-mistakesreports at all, so the author cannot judge the PR green.That is the right trade when contributing a change back. It is the wrong one when running firstmate as your own fleet.
The shape, and why this one
originhas to be the fork, becauseno-mistakesopens PRs againstoriginand exposes no per-run base override ---fork-urlonly moves the push target. Withoriginalready the fork,--fork-urlis unnecessary: push target and PR base are the same repo.gh pr createindependently defaults a fork's base repo to its parent, sogh repo set-defaultis what pins it. It recordsremote.origin.gh-resolvedin git config.The parent stays reachable as
upstream, sogit fetch upstreamkeeps working.Consequence worth knowing
/updatefirstmate(bin/fm-update.sh) fast-forwards from the remote literally namedorigin, so after this change it tracks your fork rather than the parent. That is the intended behavior once your fork is your trunk, but it means the parent's work has to be merged in deliberately fromupstream, and once you have merged your own PRs your fork'smainhas diverged from the parent and can no longer be fast-forwarded from it. Both facts are written into the new section rather than left to be rediscovered.The fixture fix
fm-teardown.shbegan sourcingbin/fm-busy-lib.sh, but neither fake-root builder intests/fm-gotmp.test.shsymlinks that sibling into itsbin/, so the real teardown subprocess aborts on the missing source:A real home always has the sibling, so this is a fixture gap only. Included here because it is what stands between this branch's base and a green CI run.
Verification
bin/fm-doc-audience-check.sh-ok surfaces=69 local_links=255bin/fm-lint.sh- clean (actionlint absent locally; CI covers workflow lint, and no workflow files changed)bin/fm-test-run.sh tests/fm-gotmp.test.sh- 3/3 pass, was 0/3 beforegit fetch upstreamresolves andupstream/mainis1cb900c, so the update path is intactgh repo set-default --viewprintsdoitdigital0495/firstmate, and this PR's own base repo is the evidence that a PR now opens against the forkExpected-red check
This PR was raised directly rather than through the
no-mistakespipeline, soRequire no-mistakesfails by design - its body carries no pipeline signature. That signature was not hand-written into this body, because forging it would defeat the check.CIis the check that matters here.