Skip to content

Latest commit

Β 

History

History
Β 
Β 

config-lerna-scopes

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Lint your commits, angular-style

@commitlint/config-lerna-scopes

Shareable commitlint config enforcing lerna package names as scopes. Use with @commitlint/cli and @commitlint/prompt-cli.

Getting started

npm install --save-dev @commitlint/config-lerna-scopes @commitlint/cli
echo "module.exports = {extends: ['@commitlint/config-lerna-scopes']};" > commitlint.config.js

Examples

❯ cat commitlint.config.js
{
  extends: ['@commitlint/config-lerna-scopes']
}

❯ tree packages

packages
β”œβ”€β”€ api
β”œβ”€β”€ app
└── web

❯ echo "buid(api): change something in api's build" | commitlint
β§—   input: build(api): change something in api's build
βœ”   found 0 problems, 0 warnings

❯ echo "test(foo): this won't pass" | commitlint
β§—   input: test(foo): this won't pass
βœ–   scope must be one of [api, app, web] [scope-enum]
βœ–   found 1 problems, 0 warnings

❯ echo "ci: do some general maintenance" | commitlint
β§—   input: ci: do some general maintenance
βœ”   found 0 problems, 0 warnings

Consult docs/rules for a list of available rules.