0.0.1 • Published 4 years ago
commitlint-plugin-regexscope v0.0.1
Commitlint Plugin Regexscope
A commitlint pulgin that supports only check regex match scope parts
Getting Started
npm install --save-dev commitlint-plugin-regexscope
And confighure commitlint.config.js
to use regexscope plugin.
module.exports = {
plugins: ['commitlint-plugin-regexscope'],
rules: {
'regexscope': [2, 'always', {
pattern: '',
clean: null,
enum: [
'core',
'ui'
],
case: 'lower-case'
}]
}
}
options: RegexScopeOptions
pattern?: string | RegExp
- specify substring which you want to check
- default:
clean?: string | RegExp
- clean your substring to match enum
- default:
null
enum?: string[]
- conditon:
regex matched subscope
is found inenum
- default:
[]
- conditon:
case?: string
- condition:
scope
is incase
- default:
lower-case
- condition:
0.0.1
4 years ago