Skip to content

Gastown pack: fall back to repo CLAUDE.md or AGENTS.md for quality-gate guidance#27

Open
brianhealey wants to merge 1 commit intogastownhall:mainfrom
brianhealey:quality-gate-fallback
Open

Gastown pack: fall back to repo CLAUDE.md or AGENTS.md for quality-gate guidance#27
brianhealey wants to merge 1 commit intogastownhall:mainfrom
brianhealey:quality-gate-fallback

Conversation

@brianhealey
Copy link

Summary

  • When pack-specific quality-gate guidance is missing or empty, agents now fall back to the repo's own instructions file (CLAUDE.md for Claude, AGENTS.md for other providers) instead of effectively skipping quality gates
  • Adds quality_gates template function that extracts the quality-gates section from the provider-specific instructions file
  • Creates shared quality-gates.md.tmpl template in the Gastown pack with hardcoded defaults as final fallback
  • Wires InstructionsFile from the resolved provider through PromptContext into template data

Test plan

  • extractQualityGates parses markdown headings correctly (6 subtests)
  • quality_gates function reads from fake FS, handles missing files and empty args
  • Template integration: function in templates, fallback behavior, provider awareness (CLAUDE.md vs AGENTS.md)
  • Shared template integration: repo fallback, default fallback, no-quality-section case
  • All existing prompt tests pass unchanged
  • Full go test ./... and go vet ./... clean

Closes w-d4dba7b056

🤖 Generated with Claude Code

…te guidance

When pack-specific quality-gate guidance is missing or empty, agents now
fall back to the repo's own instructions file (CLAUDE.md for Claude,
AGENTS.md for other providers) instead of skipping quality gates entirely.

- Add InstructionsFile to PromptContext and template data
- Add quality_gates template function that extracts the quality-gates
  section from the repo's provider-specific instructions file
- Create shared quality-gates.md.tmpl template in the Gastown pack
- Update crew.md.tmpl to use the shared template with fallback
- Wire InstructionsFile through template_resolve and cmd_prime paths

Closes w-d4dba7b056

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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