feat: adding linter for commits
This commit is contained in:
25
node_modules/conventional-changelog-conventionalcommits/parser-opts.js
generated
vendored
Normal file
25
node_modules/conventional-changelog-conventionalcommits/parser-opts.js
generated
vendored
Normal file
@@ -0,0 +1,25 @@
|
||||
'use strict'
|
||||
|
||||
module.exports = function (config) {
|
||||
config = defaultConfig(config)
|
||||
return {
|
||||
headerPattern: /^(\w*)(?:\((.*)\))?!?: (.*)$/,
|
||||
breakingHeaderPattern: /^(\w*)(?:\((.*)\))?!: (.*)$/,
|
||||
headerCorrespondence: [
|
||||
'type',
|
||||
'scope',
|
||||
'subject'
|
||||
],
|
||||
noteKeywords: ['BREAKING CHANGE'],
|
||||
revertPattern: /^(?:Revert|revert:)\s"?([\s\S]+?)"?\s*This reverts commit (\w*)\./i,
|
||||
revertCorrespondence: ['header', 'hash'],
|
||||
issuePrefixes: config.issuePrefixes
|
||||
}
|
||||
}
|
||||
|
||||
// merge user set configuration with default configuration.
|
||||
function defaultConfig (config) {
|
||||
config = config || {}
|
||||
config.issuePrefixes = config.issuePrefixes || ['#']
|
||||
return config
|
||||
}
|
||||
Reference in New Issue
Block a user