git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH] Document git-diff whitespace flags -b and -w

From
Jakub Narebski <jnareb@gmail.com>
Date
Dec 3, 2006, 16:24 UTC
Message-ID
<11651630814064-git-send-email-jnareb@gmail.com>
Document git diff options -b / --ignore-space-change and
-w / --ignore-all-space, introduced by Johannes Schindelin
in commit 0d21efa51cc7de5250d5da46bceacda78ba35373:
  "Teach diff about -b and -w flags".

The description of options is taken from GNU diff man page and GNU Diffutils info documentation.

Signed-off-by: Jakub Narebski <jnareb@gmail.com>
---
Inspired by kblin (Kai Blin) asking on #git about git-diff option to
ignore whitespace only change.
 Documentation/diff-options.txt |   16 ++++++++++++++++
 1 files changed, 16 insertions(+), 0 deletions(-)
diff --git a/Documentation/diff-options.txt b/Documentation/diff-options.txt
index e112172..9cdd171 100644
--- a/Documentation/diff-options.txt
+++ b/Documentation/diff-options.txt
@@ -129,5 +129,21 @@
 -a::
 	Shorthand for "--text".
 
+--ignore-space-change::
+	Ignore changes in amount of white space.  This ignores white
+	space at line end, and consider all other sequences of one or
+	more white space characters to be equivalent.
+
+-b::
+	Shorthand for "--ignore-space-change".
+
+--ignore-all-space::
+	Ignore white space when comparing lines.  This ignores
+	difference even if one line has white space where the other
+	line has none.
+
+-w::
+	Shorthand for "--ignore-all-space".
+
 For more detailed explanation on these common options, see also
 link:diffcore.html[diffcore documentation].
-- 
1.4.4.1
Next: Johannes Schindelin
Message 1 of 6 in “Document git-diff whitespace flags -b and -w”
  1. Document git-diff whitespace flags -b and -wJakub Narebski, Dec 3, 2006
  2. Johannes SchindelinDec 3, 2006
  3. Jakub NarebskiDec 3, 2006
  4. Johannes SchindelinDec 3, 2006
  5. Junio C HamanoDec 4, 2006
  6. Johannes SchindelinDec 4, 2006

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.