Skip to content

Commit d02833d

Browse files
committed
docs: add event type guidance for pr-title validation
Explain that pull_request does not trigger on title edits by default, and show how to add the 'edited' type to enable immediate validation.
1 parent fbc45bc commit d02833d

1 file changed

Lines changed: 11 additions & 0 deletions

File tree

‎README.md‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -148,6 +148,17 @@ jobs:
148148
> This setting only applies to `pull_request` and `pull_request_target` events;
149149
> it is silently ignored on `push` events.
150150

151+
> [!IMPORTANT]
152+
> By default, `pull_request` does **not** trigger on title changes.
153+
> To validate the PR title immediately when updated, add `edited` to your
154+
> workflow's event types:
155+
> ```yaml
156+
> on:
157+
> pull_request:
158+
> types: [opened, synchronize, reopened, edited]
159+
> ```
160+
> Without `edited`, only the initial title (at PR creation) is validated.
161+
151162
Note: the default rule of above inputs is following [this configuration](https://github.com/commit-check/commit-check-action/blob/main/commit-check.toml). If you want to customize, just add your [`commit-check.toml`](https://commit-check.github.io/commit-check/configuration.html) config file under your repository root directory.
152163

153164
## GitHub Action Job Summary

0 commit comments

Comments
 (0)