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(config): use npm config object, deprecate czConfig
Npm is generous enough to give us a config object. We should use it. This change is not breaking but
sets up 3.0.0 to be breaking by adding a deprecation warning to any repos using the old style of
config. czConfig will be removed in 3.0.0. From now on, commitizen init now uses the new config as
its default. Adds additional tests and docs as well
Closes#30
Note that if you want to force install over the top of an old adapter, you can apply the `--force` argument. For more information on this, just run `commitizen help`.
42
42
43
-
Then just add the `czConfig` field to the root of your **package.json**with the following contents:
43
+
Then just add the `config.commitizen` key to the root of your **package.json**as shown here:
44
44
45
45
```json
46
46
...
47
-
"czConfig": {
48
-
"path": "node_modules/cz-conventional-changelog"
47
+
"config": {
48
+
"commitizen": {
49
+
"path": "node_modules/cz-conventional-changelog"
50
+
}
49
51
}
50
52
```
51
53
52
54
This just tells Commitizen which adapter we actually want our contributors to use when they try to commit to this repo.
53
55
56
+
Please note that in previous version of Commitizen we used czConfig. **czConfig has been deprecated** and you should migrate to the new format before Commitizen 3.0.0.
57
+
54
58
#### Congratulations your repo is Commitizen-friendly. Time to flaunt it!
55
59
56
60
Add the Commitizen-friendly badge to your README using the following markdown:
console.error("\n********\nWARNING: You are using czConfig in your package.json. czConfig will be deprecated in Commitizen 3. \nPlease use this instead:\n{\n \"config\": {\n \"commitizen\": {\n \"path\": \"./path/to/adapter\"\n }\n }\n}\nFor more information, see: http://commitizen.github.io/cz-cli/\n********\n");
0 commit comments