Repository navigation
feat: run the repository's .workflows/setup in each new run worktree - #86
Merged
Vzlentin merged 1 commit intoNov 1, 2026
Merged
Conversation
A run worktree is a fresh checkout with no dependencies, so almost every implementer session spent its first turn on `npm ci`. A session that forgot it failed its first check. - The new module src/setup.ts runs `<worktree>/.workflows/setup` with no shell, in the worktree, after the script task creates the worktree (Git or Herdr) and before the script starts. Its stdout and stderr go to `<runDir>/setup.log`. - A setup file that is not executable fails the run and says to `chmod +x` it. A non-zero exit fails the run with `setup failed (exit <code>): <last line>; see <log>`. - The session document `workflows.setup`, keyed by the run ID, records a finished setup. A resume runs the setup again only when it did not finish. A child run in the worktree of its caller has no worktree of its own, so it runs no setup. - The progress shows a `setup` step. The new `done` progress event ends the step when the setup finishes. `Progress.stepped` now looks for any step, because the run can have no current step after `done`. - This repository gets `.workflows/setup` with a quiet `npm ci`. - docs/spec.md describes `.workflows/setup`, `setup.log` and the `setup` step. The README gives one sentence on it. - New tests cover a setup that fails and then passes at a resume, with its log and a marker file that the script reads before its first session. They also cover a file that is not executable, and a ship whose child runs do not run the setup again.
Vzlentin
deleted the
feat/run-the-repository-s-workflows-setup-in-each-new
branch
November 1, 2026 01:57
Open
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.
A run worktree is a fresh checkout with no dependencies, so almost every implementer session started with
npm ci. Now the repository declares its setup step, and the run runs it once before the first session.<worktree>/.workflows/setupin the worktree right after it creates it (Git, Herdr orinCheckout). Output goes to<runDir>/setup.log, and the progress shows asetupstep.setup failed (exit N): <last line>; see <runDir>/setup.log. A file that is not executable gets achmod +xerror.src/setup.ts), so a resume runs it again only when it did not finish. Child runs that share their caller's worktree never run it..workflows/setupwithnpm ci.BEGIN_COMMIT_OVERRIDE
chore: run the repository's .workflows/setup in each new run worktree, reverted by #87
END_COMMIT_OVERRIDE