You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: implement configuration through package.json (#75)
cz-conventional-changelog can now have its values (specifically all the defaults and maxLineWidth)
through the config.commitizen key in the package.json file. The scope now automatically becomes
lowercase (as is required for conventional changelogs) and is prompted on the same line (as it is
always short and doesn't need an additional line). The subject question now indicates the total
number of characters that are allowed based upon the maxLineWidth configuration (or 100 as it is now
by default), the length of the type, and scope. Validation prevents entering more than the allowed
number of characters with feedback of the number of characters entered. Subject will always have a
lowercase first letter and strip any trailing dots (as is required by the conventional changelog
standard). 'commitizen' and 'semantic-release' have been updated to the most recent versions
(because of current vunderabilites) and the .travisci file has been updated to reflect newer node
versions.
Part of the [commitizen](https://github.com/commitizen/cz-cli) family. Prompts for [conventional changelog](https://github.com/conventional-changelog/conventional-changelog) standard.
9
+
10
+
## Configuration
11
+
12
+
### package.json
13
+
14
+
Like commitizen, you specify the configuration of cz-conventional-changelog through the package.json's `config.commitizen` key.
The following environment varibles can be used to override any default configuration or package.json based configuration.
37
+
38
+
* CZ_TYPE = defaultType
39
+
* CZ_SCOPE = defaultScope
40
+
* CZ_SUBJECT = defaultSubject
41
+
* CZ_BODY = defaultBody
42
+
* CZ_MAX_HEADER_WIDTH = maxHeaderWidth
43
+
* CZ_MAX_LINE_WIDTH = maxLineWidth
44
+
45
+
### Commitlint
46
+
47
+
If using the [commitlint](https://github.com/conventional-changelog/commitlint) js library, the "maxHeaderWidth" configuration property will default to the configuration of the "header-max-length" rule instead of the hard coded value of 100. This can be ovewritten by setting the 'maxHeaderWidth' configuration in package.json or the CZ_MAX_HEADER_WIDTH environment variable.
0 commit comments