mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2025-08-17 10:11:38 +02:00
@ -10,7 +10,7 @@ plugins=(... git-commit)
|
||||
|
||||
## Syntax
|
||||
|
||||
```zshrc
|
||||
```zsh
|
||||
git <type> [(-s, --scope) "<scope>"] "<message>"
|
||||
```
|
||||
|
||||
@ -26,11 +26,17 @@ Where `type` is one of the following:
|
||||
- `fix`
|
||||
- `perf`
|
||||
- `refactor`
|
||||
- `revert`
|
||||
- `rev`
|
||||
- `style`
|
||||
- `test`
|
||||
|
||||
> NOTE: the alias for `revert` type is `rev`, as otherwise it conflicts with the git command of the same name.
|
||||
> It will still generate a commit message in the format `revert: <message>`
|
||||
|
||||
## Examples
|
||||
|
||||
`git style "remove trailing whitespace"` -> `git commit -m "style: remove trailing whitespace"`
|
||||
`git fix -s "router" "correct redirect link"` -> `git commit -m "fix(router): correct redirect link"`
|
||||
| Git alias | Command |
|
||||
| --------------------------------------------- | ---------------------------------------------------- |
|
||||
| `git style "remove trailing whitespace"` | `git commit -m "style: remove trailing whitespace"` |
|
||||
| `git fix -s "router" "correct redirect link"` | `git commit -m "fix(router): correct redirect link"` |
|
||||
| `git rev -s "api" "rollback v2"` | `git commit -m "revert(api): rollback v2"` |
|
||||
|
Reference in New Issue
Block a user