c713407f90e7024507c7fc621440cb171108e7f4

Author
Allan Lewis <allanlewis@users.noreply.github.com>
Committer
Marc Cornellà <marc.cornella@live.com>
Date

Message

git.plugin.zsh: Don't run Git hooks when making a WIP commit (#4751)

When making a WIP commit, we generally just want to save the state of the
current branch temporarily, maybe because we want to push our work for backup
purposes, or change branch to work on something else. Therefore, it's generally
undesirable to run Git hooks, which might do things like run linters, because
we probably don't care if our WIP has lint errors.

Diff

 1diff --git a/plugins/git/git.plugin.zsh b/plugins/git/git.plugin.zsh
 2index 25da035091cdd2495c51d12037909bd6bdace156..ea9ff8269c1447314b303d8617bef423f5c4becc 100644
 3--- a/plugins/git/git.plugin.zsh
 4+++ b/plugins/git/git.plugin.zsh
 5@@ -236,4 +236,4 @@ alias gupv='git pull --rebase -v'
 6 alias glum='git pull upstream master'
 7 
 8 alias gwch='git whatchanged -p --abbrev-commit --pretty=medium'
 9-alias gwip='git add -A; git rm $(git ls-files --deleted) 2> /dev/null; git commit -m "--wip--"'
10+alias gwip='git add -A; git rm $(git ls-files --deleted) 2> /dev/null; git commit --no-verify -m "--wip--"'