mirror of
https://github.com/neovim/neovim.git
synced 2024-12-23 20:55:18 -07:00
docs(contributing): update commit message instructions (#14758)
we are changing the way we write commits to increase automation. This commit explains how to write commit messages.
This commit is contained in:
parent
988f88c24e
commit
1df8a34a7b
@ -74,15 +74,26 @@ For Comment) and `[RDY]` (Ready).
|
|||||||
|
|
||||||
### Commit messages
|
### Commit messages
|
||||||
|
|
||||||
Follow [commit message hygiene][hygiene] to *make reviews easier* and to make
|
Follow the [convential commits guidelines][conventional_commits] to *make reviews easier* and to make
|
||||||
the VCS/git logs more valuable.
|
the VCS/git logs more valuable. The general structure of a commit message is as follows:
|
||||||
|
|
||||||
- Try to keep the first line under 72 characters.
|
```
|
||||||
- **Prefix the commit subject with a _scope_:** `doc:`, `test:`, `foo.c:`,
|
<type>([optional scope]): <description>
|
||||||
|
|
||||||
|
[optional body]
|
||||||
|
|
||||||
|
[optional footer(s)]
|
||||||
|
```
|
||||||
|
|
||||||
|
- **Prefix the commit subject with a _type_:** `doc:`, `test:`
|
||||||
`runtime:`, ...
|
`runtime:`, ...
|
||||||
- Subject line for commits with only style/lint changes can be a single
|
- Subject line for commits with only style/lint changes can be a single
|
||||||
word: `style` or `lint`.
|
word: `style` or `lint`.
|
||||||
|
- **Add the optional scope following <type> if possible:** `(lsp)`, `(treesitter)`, `(multigrid)`, ...
|
||||||
|
- Try to keep the first line under 72 characters.
|
||||||
- A blank line must separate the subject from the description.
|
- A blank line must separate the subject from the description.
|
||||||
|
- Breaking changes must be indicated at the very beginning of the footer or body section of a commit. A breaking change must consist of the uppercase text BREAKING CHANGE, followed by a colon, a space, and a description of what has changed about the API.
|
||||||
|
- Check your commit message for spelling and grammatical mistakes.
|
||||||
- Use the _imperative voice_: "Fix bug" rather than "Fixed bug" or "Fixes bug."
|
- Use the _imperative voice_: "Fix bug" rather than "Fixed bug" or "Fixes bug."
|
||||||
|
|
||||||
### Automated builds (CI)
|
### Automated builds (CI)
|
||||||
@ -222,7 +233,7 @@ as context, use the `-W` argument as well.
|
|||||||
[github-issues]: https://github.com/neovim/neovim/issues
|
[github-issues]: https://github.com/neovim/neovim/issues
|
||||||
[1820]: https://github.com/neovim/neovim/pull/1820
|
[1820]: https://github.com/neovim/neovim/pull/1820
|
||||||
[hub]: https://hub.github.com/
|
[hub]: https://hub.github.com/
|
||||||
[hygiene]: http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html
|
[conventional_commits]: https://www.conventionalcommits.org
|
||||||
[style-guide]: http://neovim.io/develop/style-guide.xml
|
[style-guide]: http://neovim.io/develop/style-guide.xml
|
||||||
[ASan]: http://clang.llvm.org/docs/AddressSanitizer.html
|
[ASan]: http://clang.llvm.org/docs/AddressSanitizer.html
|
||||||
[run-tests]: https://github.com/neovim/neovim/blob/master/test/README.md#running-tests
|
[run-tests]: https://github.com/neovim/neovim/blob/master/test/README.md#running-tests
|
||||||
|
Loading…
Reference in New Issue
Block a user