You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Scope: This is a Squad product bug affecting solo developers who work directly on main. The main-guard workflow shipped with Squad contradicts Scribe's commit behavior.
Bug: squad-main-guard.yml blocks .squad/ on protected branches but Squad commits .squad/ to working branch
The squad-main-guard.yml workflow (shipped with Squad) blocks ALL .squad/ files from being pushed to main, preview, and insider branches. However, Squad's Scribe agent commits .squad/ state (decisions.md, history.md, orchestration logs, skills) to the current working branch -- which for solo developers working directly on main means every Scribe commit triggers a guard failure.
This creates a contradiction:
Squad's Scribe is instructed to git add .squad/ && git commit after every agent batch
Squad's guard workflow rejects any push containing .squad/ files to main
Solo developers (the primary Squad audience) typically work on main
Result: Every commit to main shows a red X in the GitHub Actions tab, even though the work is correct. The guard fires on push events too (not just PRs), so direct pushes to main always fail the check.
Expected Behavior
One of:
Guard should only run on PRs, not on direct pushes -- solo devs pushing to main should not be penalized
Guard should be aware of Squad's own state files -- .squad/ is expected content on working branches; the guard should distinguish between "dev branch merged to main via PR" (block) vs "working directly on main" (allow)
Scribe should respect branch-awareness -- if on a protected branch, Scribe should skip the git commit step or use a different strategy (stash, separate branch)
Guard should be opt-in, not default -- or at minimum, the workflow should document this conflict in its comments
Reproduction Steps
Install Squad v0.9.1 on a repo
Work directly on main (common for solo projects)
Run any Squad skill that triggers Scribe (virtually all of them)
Scribe commits .squad/ changes and pushes to main
squad-main-guard.yml fires on the push event and fails
Error output:
## Forbidden files detected in PR to main
The following files must NOT be merged into main.
.squad/ are runtime team state -- they belong on dev branches only.
Forbidden files found:
- .squad/agents/bart/history.md
- .squad/agents/brockman/history.md
- .squad/decisions.md
- .squad/skills/engine-code-review/SKILL.md
- .squad/skills/goodnight/SKILL.md
...
Workflow Source
File: .github/workflows/squad-main-guard.yml
on:
pull_request:
branches: [main, preview, insider]push:
branches: [main, preview, insider] # <-- This catches direct pushes too
The forbidden path check:
if(f.startsWith('.squad/'))returntrue;// Blocks ALL .squad/ files
Impact
Every push to main shows red X in the repo's commit history and Actions tab
Misleading CI status -- the red X suggests broken code, but it's just Squad state files
Solo devs get no value from this guard -- the guard is designed for team workflows where .squad/ should stay on feature branches, but solo devs work on main
Suggested Fixes
Option A: Remove push trigger (minimal change)
on:
pull_request:
branches: [main, preview, insider]# Remove: push trigger
This preserves PR protection while allowing direct pushes (the solo dev workflow).
Option B: Add .squad/ to allowlist when on working branch
The guard could check if the push is from the repo's default branch workflow and skip .squad/ files in that case.
Option C: Make guard configurable via config.json
Read from .squad/config.json whether the guard should block .squad/ files:
{
"ci": {
"mainGuardBlockSquadFiles": false
}
}
This ties into the config-driven separation architecture from #98.
Option D: Document the conflict
At minimum, add a comment to the workflow template explaining that solo devs working on main should either:
Remove the push trigger
Or use feature branches for all work
Analysis
This bug is related to the broader upgrade/workflow architecture in #98:
The guard is overwriteOnUpgrade: true in the template manifest, so even if a solo dev removes the push trigger, squad upgrade will restore it
Bug: squad-main-guard.yml blocks .squad/ on protected branches but Squad commits .squad/ to working branch
Squad version: 0.9.1
Reporter: Wayne Berry (@WayneWalterBerry)
Repo: https://github.com/WayneWalterBerry/MMO
Problem
The
squad-main-guard.ymlworkflow (shipped with Squad) blocks ALL.squad/files from being pushed tomain,preview, andinsiderbranches. However, Squad's Scribe agent commits.squad/state (decisions.md, history.md, orchestration logs, skills) to the current working branch -- which for solo developers working directly onmainmeans every Scribe commit triggers a guard failure.This creates a contradiction:
git add .squad/ && git commitafter every agent batch.squad/files tomainmainResult: Every commit to
mainshows a red X in the GitHub Actions tab, even though the work is correct. The guard fires onpushevents too (not just PRs), so direct pushes to main always fail the check.Expected Behavior
One of:
.squad/is expected content on working branches; the guard should distinguish between "dev branch merged to main via PR" (block) vs "working directly on main" (allow)Reproduction Steps
main(common for solo projects).squad/changes and pushes tomainsquad-main-guard.ymlfires on the push event and failsError output:
Workflow Source
File:
.github/workflows/squad-main-guard.ymlThe forbidden path check:
Impact
.squad/should stay on feature branches, but solo devs work on mainSuggested Fixes
Option A: Remove
pushtrigger (minimal change)This preserves PR protection while allowing direct pushes (the solo dev workflow).
Option B: Add
.squad/to allowlist when on working branchThe guard could check if the push is from the repo's default branch workflow and skip
.squad/files in that case.Option C: Make guard configurable via config.json
Read from
.squad/config.jsonwhether the guard should block.squad/files:{ "ci": { "mainGuardBlockSquadFiles": false } }This ties into the config-driven separation architecture from #98.
Option D: Document the conflict
At minimum, add a comment to the workflow template explaining that solo devs working on
mainshould either:pushtriggerAnalysis
This bug is related to the broader upgrade/workflow architecture in #98:
overwriteOnUpgrade: truein the template manifest, so even if a solo dev removes the push trigger,squad upgradewill restore it# squad-custom: trueheader mechanism proposed in Squad product: Default workflows burn too many Actions minutes for multi-repo customers #98Related
git add .squad/ && commit).gitattributesmerge=union driver for.squad/files (designed for branch merging)