JSPM

@ptsecurity/commitlint-config

2.0.0
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 386
  • Score
    100M100P100Q90007F
  • License MIT

Commitlint configuration

Package Exports

  • @ptsecurity/commitlint-config
  • @ptsecurity/commitlint-config/commitlint.config.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@ptsecurity/commitlint-config) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

commitlint-config

Commitlint configuration

Using

Install packages:

npm i --save-dev husky @commitlint/cli @commitlint/config-conventional @ptsecurity/commitlint-config

Create file commitlint.config.js with extending preset and define set of scopes:

module.exports = {
    extends: ['@ptsecurity/commitlint-config'],
    rules: {
        'scope-enum': [ 
            2,
            'always',
            [
                // as examples
                'app', 
                'common'
            ]
        ]
    }
};

Add to package.json next section:

{
  "husky": {
    "hooks": {
      "commit-msg": "commitlint -E HUSKY_GIT_PARAMS"
    }  
  }
}

Argument -g is path to your commit configuration file. More details about it