mirror of
https://github.com/devvmhq/devvm.git
synced 2026-12-01 06:23:17 -10:00
ci: pull request titles follow Conventional Commits, as squash merges take them as the subject
Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
2 files changed
+40
No files matched your search
@@ -0,0 +1,38 @@
|
||||
name: PR title
|
||||
|
||||
# Pull requests are squash-merged with their title as the commit's subject, so the title follows
|
||||
# Conventional Commits, with the types AGENTS.md lists. pull_request, not pull_request_target: the
|
||||
# check only reads the title through the API with a read-only token and checks out no code.
|
||||
on:
|
||||
pull_request:
|
||||
types: [opened, edited, reopened, synchronize]
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
concurrency:
|
||||
group: pr-title-${{ github.event.pull_request.number }}
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
title:
|
||||
name: Conventional Commits title
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 5
|
||||
permissions:
|
||||
pull-requests: read
|
||||
steps:
|
||||
- uses: amannn/action-semantic-pull-request@2252a14e810aa9b85c2d560bd7070c802206ecf6 # v6.1.2
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
types: |
|
||||
feat
|
||||
fix
|
||||
docs
|
||||
test
|
||||
refactor
|
||||
build
|
||||
ci
|
||||
chore
|
||||
requireScope: false
|
||||
@@ -9,3 +9,5 @@ Before sending a change, run:
|
||||
```sh
|
||||
mise run fmt && mise run lint && mise run test
|
||||
```
|
||||
|
||||
Pull requests are squash-merged, and the pull request's title becomes the commit's subject, so write it as a [Conventional Commit](https://www.conventionalcommits.org/), `type(scope): summary`, with a type of `feat`, `fix`, `docs`, `test`, `refactor`, `build`, `ci` or `chore`. A check fails a title that doesn't follow it.
|
||||
Reference in new issue
Block a user