feat: implement automated versioning with Release Please #8
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Copyright (c) Microsoft Corporation. | |
| # Licensed under the MIT license. | |
| name: PR Title Lint | |
| on: | |
| pull_request: | |
| types: [opened, edited, synchronize, reopened] | |
| permissions: | |
| pull-requests: read | |
| jobs: | |
| pr-title-lint: | |
| name: Validate PR Title | |
| runs-on: ubuntu-latest | |
| steps: | |
| # Pinned to commit SHA for supply chain security (CWE-829) | |
| # Verify: gh api repos/amannn/action-semantic-pull-request/git/ref/tags/v5.5.3 --jq '.object.sha' | |
| - uses: amannn/action-semantic-pull-request@0723387faaf9b38adef4775cd42cfd5155ed6017 # v5.5.3 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| with: | |
| # Configure which types are allowed (see https://github.com/commitizen/conventional-commit-types) | |
| types: | | |
| feat | |
| fix | |
| docs | |
| style | |
| refactor | |
| perf | |
| test | |
| build | |
| ci | |
| chore | |
| revert | |
| deps | |
| # Configure which scopes are allowed (empty means all scopes are allowed) | |
| scopes: | | |
| # Configure whether a scope must be provided (false means scopes are optional) | |
| requireScope: false | |
| # For work-in-progress PRs you can typically use draft pull requests | |
| # Instead of allowing WIP in the title | |
| wip: true | |
| # Configure validation of the subject line (title after type/scope) | |
| subjectPattern: ^(?![A-Z]).+$ | |
| subjectPatternError: | | |
| The subject "{subject}" found in the pull request title "{title}" | |
| must start with a lowercase letter. | |
| # If the PR contains only a single commit, validate that its message matches the PR title | |
| validateSingleCommit: false |