We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3fa5f63 commit 60b2790Copy full SHA for 60b2790
.github/workflows/commit-msg-checker.yml
@@ -0,0 +1,12 @@
1
+# https://github.com/marketplace/actions/conventional-commit-lint
2
+
3
+name: Conventional Commit Lint
4
5
+on: [push, pull_request]
6
7
+jobs:
8
+ commit-lint:
9
+ runs-on: ubuntu-20.04
10
+ steps:
11
+ # conventional style
12
+ - uses: ahmadnassri/action-commit-lint@v2.0.4
.husky/init.sh
@@ -0,0 +1,15 @@
+#!/bin/bash
+cd ..
+# 安装 husky
+npm install -g husky
+# 安装 husky git hooks
+npx husky install
+# commitlint 安装配置
+npm install -g @commitlint/cli @commitlint/config-conventional
13
+echo "module.exports = {extends: ['@commitlint/config-conventional']}" > ../commitlint.config.js
14
15
+npx husky add .husky/commit-msg 'npx --no-install commitlint --edit "$1"'
0 commit comments