fix: require PR template check before creating PRs #8660

Open
opened 2026-02-16 18:10:31 -05:00 by yindo · 0 comments
Owner

Originally created by @scarf005 on GitHub (Feb 5, 2026).

Originally assigned to: @thdxr on GitHub.

Problem

The bash tool's "Creating pull requests" section has a hardcoded example format (## Summary) that agents blindly follow, ignoring project-specific PR templates.

Solution

  1. Use Glob tool to flexibly find template files:

    • **/pull_request_template.md, **/PULL_REQUEST_TEMPLATE.md
    • **/AGENTS.md, **/CONTRIBUTING.md
  2. Provide fallback format when no template exists

  3. Remove hardcoded example that causes agents to ignore templates

Impact

Agents will:

  • Use Glob to find templates anywhere in repo
  • Follow project templates when they exist
  • Use consistent fallback format when no template exists
Originally created by @scarf005 on GitHub (Feb 5, 2026). Originally assigned to: @thdxr on GitHub. ## Problem The bash tool's "Creating pull requests" section has a hardcoded example format (`## Summary`) that agents blindly follow, ignoring project-specific PR templates. ## Solution 1. Use Glob tool to flexibly find template files: - `**/pull_request_template.md`, `**/PULL_REQUEST_TEMPLATE.md` - `**/AGENTS.md`, `**/CONTRIBUTING.md` 2. Provide fallback format when no template exists 3. Remove hardcoded example that causes agents to ignore templates ## Impact Agents will: - Use Glob to find templates anywhere in repo - Follow project templates when they exist - Use consistent fallback format when no template exists
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#8660