path: root/Documentation/git-stripspace.txt
diff options
authorJunio C Hamano <>2013-01-16 19:18:48 (GMT)
committerJunio C Hamano <>2013-01-16 20:48:22 (GMT)
commiteff80a9fd990de3605063050dae32f969ef18ba8 (patch)
tree6a7b0c000cea480ac8e2714cbbf92691b7237b55 /Documentation/git-stripspace.txt
parent44fe83502edf5391bb3a5997cab01794b4568062 (diff)
Allow custom "comment char"
Some users do want to write a line that begin with a pound sign, #, in their commit log message. Many tracking system recognise a token of #<bugid> form, for example. The support we offer these use cases is not very friendly to the end users. They have a choice between - Don't do it. Avoid such a line by rewrapping or indenting; and - Use --cleanup=whitespace but remove all the hint lines we add. Give them a way to set a custom comment char, e.g. $ git -c core.commentchar="%" commit so that they do not have to do either of the two workarounds. [jc: although I started the topic, all the tests and documentation updates, many of the call sites of the new strbuf_add_commented_*() functions, and the change to scripted Porcelain are from Ralf.] Signed-off-by: Junio C Hamano <> Signed-off-by: Ralf Thielow <> Signed-off-by: Junio C Hamano <>
Diffstat (limited to 'Documentation/git-stripspace.txt')
1 files changed, 7 insertions, 1 deletions
diff --git a/Documentation/git-stripspace.txt b/Documentation/git-stripspace.txt
index a80d946..e6fdfcb 100644
--- a/Documentation/git-stripspace.txt
+++ b/Documentation/git-stripspace.txt
@@ -35,7 +35,13 @@ OPTIONS
- Skip and remove all lines starting with '#'.
+ Skip and remove all lines starting with comment character (default '#').
+ Prepend comment character and blank to each line. Lines will automatically
+ be terminated with a newline. On empty lines, only the comment character
+ will be prepended.