Skip to content

Commit

Permalink
chore: check PR conventional commit name (#201)
Browse files Browse the repository at this point in the history
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **Chores**
- Introduced a GitHub Actions workflow to validate pull request titles.
  - Added a commit linting job to the existing Python build workflow.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
  • Loading branch information
rokam authored Jul 5, 2024
1 parent e67a3f1 commit 330b80f
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 0 deletions.
17 changes: 17 additions & 0 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: "Lint PR"

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

permissions:
pull-requests: read

jobs:
main:
name: Validate PR title
runs-on: ubuntu-latest
steps:
- uses: amannn/action-semantic-pull-request@v5
env:
GITHUB_TOKEN: ${{ secrets.MIDEA_GITHUB_PAT }}
8 changes: 8 additions & 0 deletions .github/workflows/python-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,15 @@ on:
branches: ["main"]

jobs:
commitlint:
name: Lint Commit Messages
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: wagoid/commitlint-github-action@v6.0.1
build:
needs:
- commitlint
runs-on: ${{ matrix.os }}
strategy:
matrix:
Expand Down

0 comments on commit 330b80f

Please sign in to comment.