-
-
Notifications
You must be signed in to change notification settings - Fork 301
feat(bump): it is now possible to specify a pattern in the files attr... #25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,40 +1,42 @@ | ||
# Configuration | ||
|
||
**New!** Support for `pyproject.toml` | ||
Commitizen has support for `toml` and `ini` files. | ||
|
||
Add an entry to `pyproject.toml`. | ||
## pyproject.toml | ||
|
||
Add an entry to `pyproject.toml`. Recommended for **python** projects. | ||
|
||
[tool.commitizen] | ||
name = "cz_conventional_commits" | ||
version = "0.1.0" | ||
files = [ | ||
"src/__version__.py", | ||
"pyproject.toml" | ||
"pyproject.toml:version" | ||
] | ||
|
||
## INI files | ||
|
||
Also, you can create in your project folder a file called `.cz`, | ||
`.cz.cfg` or in your `setup.cfg` or if you want to configure the global | ||
default in your user's home folder a `.cz` file with the following | ||
information: | ||
Supported files: `.cz`, `.cz.cfg`, `setup.py`, and `$HOME/.cz` | ||
|
||
The format is slightly different to the `toml`, so pay attention. | ||
Recommended for **other languages** projects (js, go, etc). | ||
|
||
[commitizen] | ||
name = cz_conventional_commits | ||
version = 0.1.0 | ||
files = [ | ||
"src/__version__.py", | ||
"pyproject.toml" | ||
"pyproject.toml:version" | ||
] | ||
|
||
The extra tab at the end (`]`) is required. | ||
The extra tab before the square brakets (`]`) at the end is required. | ||
|
||
## Settings | ||
|
||
| Variable | Type | Default | Description | | ||
| -------- | ---- | ------- | ----------- | | ||
| `name` | `str` | `"cz_conventional_commits"` | Name of the commiting rules to use | | ||
| `version` | `str` | `None` | Current version. Example: "0.1.2" | | ||
| `files` | `list` | `[ ]` | Files were the version needs to be updated | | ||
| `tag_format` | `str` | `None` | Format for the git tag, useful for old projects, that use a convention like `"v1.2.1"`. [See more](/bump#configuration) | | ||
| `bump_message` | `str` | `None` | Create custom commit message, useful to skip ci. [See more](/bump#configuration) | | ||
| `files` | `list` | `[ ]` | Files were the version will be updated. A pattern to match a line, can also be specified, separated by `:` [See more](https://woile.github.io/commitizen/bump#files) | | ||
| `tag_format` | `str` | `None` | Format for the git tag, useful for old projects, that use a convention like `"v1.2.1"`. [See more](https://woile.github.io/commitizen/bump#tag_format) | | ||
| `bump_message` | `str` | `None` | Create custom commit message, useful to skip ci. [See more](https://woile.github.io/commitizen/bump#bump_message) | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.