-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: enable commitlinter with conventional rules
Signed-off-by: Artsiom Koltun <[email protected]>
- Loading branch information
1 parent
535f853
commit cf4024a
Showing
3 changed files
with
48 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"extends": [ | ||
"@commitlint/config-conventional" | ||
] | ||
} | ||
|
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
name: Commitlint | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
commitlint: | ||
if: ${{ github.event.pull_request.merged != true }} | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
Check warning Code scanning / Scorecard Pinned-Dependencies Medium
score is 6: GitHub-owned GitHubAction not pinned by hash
Click Remediation section below to solve this issue |
||
with: | ||
fetch-depth: 0 | ||
- name: Setup Node | ||
uses: actions/setup-node@v2 | ||
Check warning Code scanning / Scorecard Pinned-Dependencies Medium
score is 6: GitHub-owned GitHubAction not pinned by hash
Click Remediation section below to solve this issue |
||
with: | ||
node-version: 20.x | ||
- name: Install dependencies | ||
run: npm i -g @commitlint/cli @commitlint/config-conventional | ||
- name: Validate all commits from PR | ||
Check warning Code scanning / Scorecard Pinned-Dependencies Medium
score is 6: npmCommand not pinned by hash
Click Remediation section below to solve this issue |
||
run: commitlint --config ./.commitlintrc.json --from ${{ github.event.pull_request.base.sha }} --to ${{ github.event.pull_request.head.sha }} --verbose |
This file contains 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