Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit e08d0d5

Browse files
docs: add encoding configuration
1 parent c1b2733 commit e08d0d5

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

‎docs/config.md‎

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -184,6 +184,14 @@ Default: `[]`
184184

185185
Calls the hook scripts **after** bumping the version. [Read more][post_bump_hooks]
186186

187+
### `encoding`
188+
189+
Type: `str`
190+
191+
Default: `utf-8`
192+
193+
Sets the character encoding to be used when parsing commit messages. [Read more][encoding]
194+
187195
## Configuration file
188196

189197
### pyproject.toml or .cz.toml
@@ -357,3 +365,4 @@ setup(
357365
[customization]: customization.md
358366
[shortcuts]: customization.md#shortcut-keys
359367
[annotated-tags-vs-lightweight]: https://stackoverflow.com/a/11514139/2047185
368+
[encoding]: tutorials/writing_commits.md#writing-commits

‎docs/tutorials/writing_commits.md‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ Now to the important part, when writing commits, it's important to think about:
2323
You may think this is trivial, but it's not. It's important for the reader to
2424
understand what happened.
2525

26+
Emojis may be added as well (e.g. see [cz-emoji][cz_emoji]), which requires the `utf-8`, or equivalent, character encoding to support unicode characters. By default, `commitizen` uses the `utf-8` character encoding, but a different encoding may be set through the `encoding` [configuration option][configuration].
27+
2628
### Recommendations
2729

2830
- **Keep the message short**: Makes the list of commits more readable (~50 chars).
@@ -40,3 +42,5 @@ understand what happened.
4042

4143
[customization]: ../customization.md
4244
[conventional_commits]: https://www.conventionalcommits.org
45+
[cz_emoji]: https://commitizen-tools.github.io/commitizen/third-party-commitizen/#cz-emoji
46+
[configuration]: ../config.md#encoding

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /