Skip to content

docs: update PR template to follow conventional commits#184

Merged
jlia0 merged 1 commit intomainfrom
jlia0/pr-template-conv-commit
Mar 9, 2026
Merged

docs: update PR template to follow conventional commits#184
jlia0 merged 1 commit intomainfrom
jlia0/pr-template-conv-commit

Conversation

@jlia0
Copy link
Copy Markdown
Collaborator

@jlia0 jlia0 commented Mar 9, 2026

Update the pull request template to enforce conventional commit format for titles and descriptions. This includes clear guidance on commit types, scope, imperative mood, and provides examples to help contributors write better PR titles and messages.

The template now removes generic checkboxes in favor of explicit conventional commit instructions, making it easier for contributors to follow the project's standards.

Changes

  • Add conventional commit format guidance to PR title section
  • Add conventional commit description guidelines
  • Remove "Type of Change" checkboxes (now covered by commit type prefix)
  • Add checklist item for verifying conventional commit title format

Testing

Tested locally with this PR

Improve PR template with conventional commit guidance for titles and descriptions, including type/scope format, examples, and best practices for commit messages. Replace generic type checkboxes with more explicit conventional commit instructions.

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
@greptile-apps
Copy link
Copy Markdown

greptile-apps Bot commented Mar 9, 2026

Greptile Summary

This PR updates .github/pull_request_template.md to enforce conventional commit format for PR titles and descriptions, removing the old "Type of Change" checkboxes in favor of structured type-prefix guidance and a new checklist item. The changes are straightforward and improve contributor experience for a project that follows conventional commits.

  • Adds a ## PR Title section with conventional commit format instructions (inside an HTML comment)
  • Adds a ## Description section replacing the old ## Summary, with guidance on imperative mood and breaking-change notation
  • Removes the "Type of Change" checkbox list (now covered by the commit type prefix)
  • Adds a checklist item: PR title follows conventional commit format
  • The ## PR Title section heading will render as an empty orphaned heading in submitted PRs once the HTML comment is stripped — consider replacing the section heading with a freestanding comment or relying solely on the checklist item
  • The ## Description section is missing a fill-in placeholder (unlike ## Changes and ## Testing), which may cause contributors to leave the section blank

Confidence Score: 4/5

  • Safe to merge — purely a documentation/template update with no functional impact.
  • The change is limited to a single Markdown template file and has no effect on code behavior. Two minor style issues exist (empty rendered heading and missing placeholder), but neither blocks contributors from using the template correctly.
  • .github/pull_request_template.md — review the two style comments around the ## PR Title empty heading and the missing ## Description placeholder.

Important Files Changed

Filename Overview
.github/pull_request_template.md Adds conventional commit guidance to PR title and description sections, removes "Type of Change" checkboxes, and adds a checklist item for format verification. Two minor style issues: the ## PR Title heading renders as an empty section after submission, and ## Description is missing a fill-in placeholder.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[Contributor opens a new PR] --> B[GitHub loads pull_request_template.md]
    B --> C[Editor view: HTML comments visible\nContributor reads conventional commit guidance]
    C --> D{Follows conventional\ncommit format?}
    D -- Yes --> E[type scope : description\ne.g. feat cli : add --verbose flag]
    D -- No --> F[Revise title using\nTypes: feat fix docs style refactor\nperf test build ci chore]
    F --> E
    E --> G[Fill in ## Description\nusing imperative mood]
    G --> H[Fill in ## Changes bullet list]
    H --> I[Fill in ## Testing notes]
    I --> J{Checklist\nPR title follows\nconventional commit format?}
    J -- Checked --> K[Submit PR]
    J -- Not checked --> L[Fix title or description\nthen re-check]
    L --> J
    K --> M[Reviewer sees rendered PR body\nNote: PR Title heading appears\nas empty section after submission]
Loading

Last reviewed commit: d402869

Comment on lines +1 to +15
## PR Title

<!-- Brief description of what this PR does and why -->
<!--
Use conventional commit format for the PR title:

<type>(<scope>): <short description>

Types: feat, fix, docs, style, refactor, perf, test, build, ci, chore
Scope is optional but encouraged (e.g., cli, api, config)

Examples:
feat(cli): add --verbose flag for debug output
fix(api): handle null response from provider
docs: update README with setup instructions
-->
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

## PR Title section renders as empty heading in submitted PR

The ## PR Title section, along with its guidance comment, will only be visible in the PR editor — once a PR is submitted, the HTML comment is stripped and the heading ## PR Title is left as an empty, orphaned section in the rendered PR body. This can look confusing to reviewers reading the submitted PR.

Since PR title guidance is already reinforced by the new checklist item (- [ ] PR title follows conventional commit format), consider removing the ## PR Title heading entirely and keeping only the HTML comment as a freestanding hint at the top of the template — or simply rely on the checklist item alone.

Suggested change
## PR Title
<!-- Brief description of what this PR does and why -->
<!--
Use conventional commit format for the PR title:
<type>(<scope>): <short description>
Types: feat, fix, docs, style, refactor, perf, test, build, ci, chore
Scope is optional but encouraged (e.g., cli, api, config)
Examples:
feat(cli): add --verbose flag for debug output
fix(api): handle null response from provider
docs: update README with setup instructions
-->
<!--
Use conventional commit format for the PR title:
<type>(<scope>): <short description>
Types: feat, fix, docs, style, refactor, perf, test, build, ci, chore
Scope is optional but encouraged (e.g., cli, api, config)
Examples:
feat(cli): add --verbose flag for debug output
fix(api): handle null response from provider
docs: update README with setup instructions
-->
## Description

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

Comment on lines +17 to +27
## Description

<!--
Explain what this PR does and why. Use conventional commit style:

- Start with the imperative mood (e.g., "add", "fix", "remove", not "added", "fixes")
- First line: concise summary of the change
- Body: motivation, context, and details of the approach

If this is a breaking change, start the body with "BREAKING CHANGE:" and explain the impact.
-->
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

## Description section missing a fill-in placeholder

Unlike ## Changes and ## Testing, the ## Description section has no placeholder text (e.g., a - or a short prompt) below the comment. The comment itself is hidden after submission, so if a contributor never replaces it, the section silently renders as empty. Adding a minimal placeholder makes it clear that content is expected here.

Suggested change
## Description
<!--
Explain what this PR does and why. Use conventional commit style:
- Start with the imperative mood (e.g., "add", "fix", "remove", not "added", "fixes")
- First line: concise summary of the change
- Body: motivation, context, and details of the approach
If this is a breaking change, start the body with "BREAKING CHANGE:" and explain the impact.
-->
## Description
<!--
Explain what this PR does and why. Use conventional commit style:
- Start with the imperative mood (e.g., "add", "fix", "remove", not "added", "fixes")
- First line: concise summary of the change
- Body: motivation, context, and details of the approach
If this is a breaking change, start the body with "BREAKING CHANGE:" and explain the impact.
-->

@jlia0 jlia0 merged commit 17adc9c into main Mar 9, 2026
1 check passed
@jlia0 jlia0 deleted the jlia0/pr-template-conv-commit branch March 9, 2026 18: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