summaryrefslogtreecommitdiff
path: root/Documentation
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2011-05-23 16:58:31 (GMT)
committerJunio C Hamano <gitster@pobox.com>2011-05-23 16:58:31 (GMT)
commitb7aba2ef3450832828148e1a71b6a7198614b43d (patch)
treec9d052589c13471a50ecfeb96692b2c4243f0607 /Documentation
parent391b14278e59f46ceda3b055fdc12527bc2c87fb (diff)
parented747dd5216ba1fe6fa59da9585dcd6cced202bb (diff)
downloadgit-b7aba2ef3450832828148e1a71b6a7198614b43d.zip
git-b7aba2ef3450832828148e1a71b6a7198614b43d.tar.gz
git-b7aba2ef3450832828148e1a71b6a7198614b43d.tar.bz2
Merge branch 'jk/blame-line-porcelain'
* jk/blame-line-porcelain: blame: add --line-porcelain output format blame: refactor porcelain output add tests for various blame formats
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/blame-options.txt5
-rw-r--r--Documentation/git-blame.txt13
2 files changed, 18 insertions, 0 deletions
diff --git a/Documentation/blame-options.txt b/Documentation/blame-options.txt
index 16e3c68..e76195a 100644
--- a/Documentation/blame-options.txt
+++ b/Documentation/blame-options.txt
@@ -52,6 +52,11 @@ of lines before or after the line given by <start>.
--porcelain::
Show in a format designed for machine consumption.
+--line-porcelain::
+ Show the porcelain format, but output commit information for
+ each line, not just the first time a commit is referenced.
+ Implies --porcelain.
+
--incremental::
Show the result incrementally in a format designed for
machine consumption.
diff --git a/Documentation/git-blame.txt b/Documentation/git-blame.txt
index bb8edb4..9516914 100644
--- a/Documentation/git-blame.txt
+++ b/Documentation/git-blame.txt
@@ -105,6 +105,19 @@ The contents of the actual line is output after the above
header, prefixed by a TAB. This is to allow adding more
header elements later.
+The porcelain format generally suppresses commit information that has
+already been seen. For example, two lines that are blamed to the same
+commit will both be shown, but the details for that commit will be shown
+only once. This is more efficient, but may require more state be kept by
+the reader. The `--line-porcelain` option can be used to output full
+commit information for each line, allowing simpler (but less efficient)
+usage like:
+
+ # count the number of lines attributed to each author
+ git blame --line-porcelain file |
+ sed -n 's/^author //p' |
+ sort | uniq -c | sort -rn
+
SPECIFYING RANGES
-----------------