Skip to content

Commit

Permalink
chore: [DevOps] PR Title Linter (#273)
Browse files Browse the repository at this point in the history
  • Loading branch information
MatKuhr authored Jan 16, 2025
1 parent 602bbe0 commit 44700cf
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 1 deletion.
33 changes: 33 additions & 0 deletions .github/workflows/pr-lint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: lint pr

on:
pull_request_target:
types:
- opened
- edited
- synchronize

permissions:
pull-requests: read

jobs:
lint-pr:
runs-on: ubuntu-latest
steps:
- uses: amannn/action-semantic-pull-request@v5
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
scopes: |
Core
OpenAI
Orchestration
DevOps
headerPattern: '^(\w.+): (?:\[(\w.+)\] )?(.+)$'
headerPatternCorrespondence: type, scope, subject
# for available types, check:
# /~https://github.com/commitizen/conventional-commit-types/blob/master/index.json
subjectPatternError: |
The subject "{subject}" found in the pull request title "{title}"
didn't match the configured pattern. Please ensure that the subject
starts with an uppercase character, e.g. "feat: New Feature".
2 changes: 1 addition & 1 deletion .github/workflows/prepare-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ jobs:
run: |
COMMIT_URL=${{ github.event.repository.html_url }}/commit/${{ needs.bump-version.outputs.release-commit }}
PR_URL=$(gh pr create --title "Release ${{ needs.bump-version.outputs.release-version }}" --body "## TODOs
PR_URL=$(gh pr create --title "feat: Release ${{ needs.bump-version.outputs.release-version }}" --body "## TODOs
- [ ] Review the changes in [the release commit]($COMMIT_URL)
- [ ] Review the [Draft Release](${{ needs.create-release.outputs.release-url }})
- [ ] Review **and approve** this PR
Expand Down

0 comments on commit 44700cf

Please sign in to comment.