summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 2ea7fe0)
raw | patch | inline | side by side (parent: 2ea7fe0)
author | Wincent Colaiuta <win@wincent.com> | |
Sat, 8 Dec 2007 11:38:07 +0000 (12:38 +0100) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Sun, 9 Dec 2007 08:55:54 +0000 (00:55 -0800) |
At the moment the --no-verify switch to "git commit" instructs it to
skip over the pre-commit hook. Here we teach "git commit --no-verify"
to skip over the commit-msg hook as well. This brings the behaviour
of builtin-commit back in line with git-commit.sh.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
skip over the pre-commit hook. Here we teach "git commit --no-verify"
to skip over the commit-msg hook as well. This brings the behaviour
of builtin-commit back in line with git-commit.sh.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin-commit.c | patch | blob | history |
diff --git a/builtin-commit.c b/builtin-commit.c
index 19297ac027ab88ffe01d4b9b5dc12c7ae556f6c1..2032ca314c1c7d9b6fd45128bb30bfe2c36f1792 100644 (file)
--- a/builtin-commit.c
+++ b/builtin-commit.c
rollback_index_files();
die("could not read commit message");
}
- if (run_hook(index_file, "commit-msg", git_path(commit_editmsg))) {
+ if (!no_verify &&
+ run_hook(index_file, "commit-msg", git_path(commit_editmsg))) {
rollback_index_files();
exit(1);
}