Skip to content

Keep doctor repairs working on main-only repos and simplify managed ignores#209

Merged
NagyVikt merged 1 commit into
mainfrom
agent/codex/ignore-scripts-star-and-githooks-2026-04-21-10-40
Apr 21, 2026
Merged

Keep doctor repairs working on main-only repos and simplify managed ignores#209
NagyVikt merged 1 commit into
mainfrom
agent/codex/ignore-scripts-star-and-githooks-2026-04-21-10-40

Conversation

@NagyVikt

Copy link
Copy Markdown
Collaborator

Automated by scripts/agent-branch-finish.sh (PR flow).

…gnores

Guardex was still enumerating managed scripts and hook files one by one in the generated .gitignore block. The protected-main doctor sandbox finish flow also let branch finish fall back to the default base branch, which broke main-only repos with 'fatal: invalid reference: dev' and could leave AGENTS.md repairs incomplete even though setup/doctor are supposed to restore them.

Constraint: Users expect gx setup and gx doctor to ignore Guardex-owned scripts and hooks as managed directories
Constraint: Protected-main doctor auto-finish must stay on the actual protected base branch
Rejected: Keep per-file script and hook ignore entries | drifts whenever new managed files land
Confidence: high
Scope-risk: moderate
Reversibility: clean
Directive: Pass the active protected base branch through doctor sandbox finish flow; do not let it fall back to the repo default base
Tested: node --check bin/multiagent-safety.js
Tested: node --test --test-name-pattern "setup provisions workflow files and repo config|setup appends managed gitignore block without clobbering existing entries|doctor on protected main auto-commits sandbox repairs and runs PR finish flow when gh is authenticated|doctor recurses into nested frontend repos and repairs protected-main drift" test/install.test.js
Tested: openspec validate agent-codex-ignore-scripts-star-and-githooks-2026-04-21-10-40 --type change --strict
Tested: openspec validate --specs
Not-tested: Full node --test test/install.test.js suite
@NagyVikt NagyVikt merged commit 7083bb4 into main Apr 21, 2026
@NagyVikt NagyVikt deleted the agent/codex/ignore-scripts-star-and-githooks-2026-04-21-10-40 branch April 21, 2026 08:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant