Skip to content

Commit

Permalink
ci: Add commit name linter for PRs (#35)
Browse files Browse the repository at this point in the history
* Add commit name linter

* Goodbye angular
  • Loading branch information
ethanuppal authored Dec 9, 2024
1 parent 47f1570 commit d58e467
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 0 deletions.
File renamed without changes.
18 changes: 18 additions & 0 deletions .github/workflows/pr.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# https://github.com/satellytes/commitlint-pr-title
name: PR Style

on:
pull_request:
types: [opened, reopened, edited, synchronize]
branches: [main]

jobs:
title-lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- name: manually install any commitlint presets that we extend from
run: npm install --no-save @commitlint/config-conventional

- uses: satellytes/commitlint-pr-title@v1
9 changes: 9 additions & 0 deletions commitlint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
module.exports = {
rules: {
'type-enum': [
2,
'always',
['chore', 'ci', 'docs', 'feat', 'fix', 'refactor', 'revert', 'test']
],
}
};

0 comments on commit d58e467

Please sign in to comment.