Skip to content
Merged
Show file tree
Hide file tree
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
4 changes: 4 additions & 0 deletions .github/LABELS.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,10 @@ labels (e.g. `frontend`, `backend`, `connector: <name>`, `collector: <name>`,
`agents`, `authentication`). They add routing context and an issue may carry
more than one. They are not listed in `labels.yml`.

All label names are **lowercase**. Repository-specific labels use a neutral grey
color (`ededed`); only the shared labels above carry color, so the common
taxonomy stands out consistently across every Filigran repository.

## 5. Deprecated labels — do not use

- `enhancement` — use `feature`.
Expand Down
46 changes: 46 additions & 0 deletions .github/workflows/validate-pr-title.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Validate PR Title

on:
pull_request:
types: [opened, edited, reopened, ready_for_review, synchronize]

permissions:
contents: read

jobs:
validate-pr-title:
name: Validate Conventional PR title
runs-on: ubuntu-latest
if: github.event.pull_request.user.login != 'renovate[bot]' && !startsWith(github.event.pull_request.title, '[Snyk]')
steps:
- name: Check Conventional Commit title
env:
TITLE: ${{ github.event.pull_request.title }}
run: |
set -euo pipefail

echo "PR title: ${TITLE}"

# Filigran-wide Conventional Commits convention.
ALLOWED_TYPES='feat|fix|docs|style|refactor|perf|test|build|ci|chore|revert'

# Required format: type(scope?)!?: description (#123)
PATTERN="^(${ALLOWED_TYPES})(\([a-z0-9]+([_-][a-z0-9]+)*(\/[a-z0-9]+([_-][a-z0-9]+)*)*\))?!?: [a-z0-9].* \(#[0-9]+\)$"

if [[ "${TITLE}" =~ ${PATTERN} ]]; then
echo "PR title is valid."
exit 0
fi

echo "Invalid PR title."
echo ""
echo "Required format:"
echo " type(scope?): description (#123)"
echo ""
echo "Allowed types:"
echo " feat, fix, docs, style, refactor, perf, test, build, ci, chore, revert"
echo ""
echo "Examples:"
echo " feat(api): add bulk export endpoint (#871)"
echo " fix: handle missing auth token (#456)"
exit 1