Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions .github/workflows/pr-title.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: pr-title

# Conventional Commits PR-title gate. Consumes the shared semantic-pr reusable
# workflow from ci-workflows. Repos are squash-only with the squash title set to
# PR_TITLE, so the PR title becomes the default-branch subject — this gates the
# Conventional-Commits history. `edited` re-validates on a re-title. The emitted
# required-check context is `pr-title / pr-title`.
on:
pull_request:

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Run the title gate from the base workflow

Since this check is intended to become a required ruleset gate, running it on pull_request leaves the policy controlled by the PR's merge commit: a PR that edits .github/workflows/pr-title.yml can relax or replace the pr-title / pr-title job and still satisfy the required check with a non-Conventional title. GitHub documents pull_request_target as running in the default-branch context rather than the PR merge context, and this workflow only reads PR metadata without checking out head code, so using pull_request_target would enforce the base branch's gate while avoiding this bypass.

Useful? React with 👍 / 👎.

types: [opened, edited, reopened, synchronize]

permissions:
pull-requests: read

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
pr-title:
permissions:
pull-requests: read
uses: melodic-software/ci-workflows/.github/workflows/semantic-pr.yml@f82733b00c623254e2d2d2407aca205ae58fb7e4
Loading