Skip to content

Commit 3bebce8

Browse files
committed
ci(common): merge commitlint ruleset and action
1 parent fcc1f9b commit 3bebce8

File tree

2 files changed

+16
-1
lines changed

2 files changed

+16
-1
lines changed

.github/config/commitlint.config.js

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,21 @@ const Configuration = {
2020
*/
2121
rules: {
2222
'type-empty': [RuleConfigSeverity.Error, 'never'],
23+
'scope-enum': [RuleConfigSeverity.Error, 'always',
24+
[
25+
'coprocessor',
26+
'host-contracts',
27+
'gateway-contracts',
28+
'protocol-contracts',
29+
'contracts',
30+
'library-solidity',
31+
'kms-connector',
32+
'sdk',
33+
'test-suite',
34+
'charts',
35+
'common'
36+
]
37+
],
2338
},
2439
};
2540

.github/workflows/common-pull-request-lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ jobs:
4242
run: |
4343
npm install @commitlint/config-conventional@^18 conventional-changelog-conventionalcommits @commitlint/types@^18
4444
npm install -g @commitlint/cli@^18
45-
npx commitlint --config .github/config/commitlint.config.js --from "${BASE_SHA}" --to "${HEAD_SHA}" --verbose
45+
echo "${{ github.event.pull_request.title }}" | npx commitlint --config .github/config/commitlint.config.js --verbose
4646
4747
- name: Run zizmor 🌈
4848
uses: zizmorcore/zizmor-action@e673c3917a1aef3c65c972347ed84ccd013ecda4 # v0.2.0

0 commit comments

Comments
 (0)