[PATCH] fix documentation for git-commit --no-verify

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Despite what the documentation claims, git-commit does not check commit
for suspicious lines: all hooks are disabled by default,
and the pre-comit hook could be changed to do something else.

Signed-off-by: Michael S. Tsirkin <mst@xxxxxxxxxxxxxx>

---

> Quoting Michael S. Tsirkin <mst@xxxxxxxxxxxxxx>:
> Subject: git-commit/git-applypatch whitespace rules different?
> 
> git-commit/git-applypatch whitespace rules seem to be different.
> Is this expected?

OK I found out why this happens, but the documentation can be improved.

diff --git a/Documentation/git-commit.txt b/Documentation/git-commit.txt
index a7adf24..cb081cd 100644
--- a/Documentation/git-commit.txt
+++ b/Documentation/git-commit.txt
@@ -72,12 +72,8 @@ OPTIONS
 	Add Signed-off-by line at the end of the commit message.
 
 --no-verify::
-	By default, the command looks for suspicious lines the
-	commit introduces, and aborts committing if there is one.
-	The definition of 'suspicious lines' is currently the
-	lines that has trailing whitespaces, and the lines whose
-	indentation has a SP character immediately followed by a
-	TAB character.  This option turns off the check.
+	This option bypasses the pre-commit hook.
+	See also link:hooks.html[hooks].
 
 -e|--edit::
 	The message taken from file with `-F`, command line with
-- 
MST
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]