git-blame(1): mention options in the synopsis and advertise pickaxe
Inspired by the cvs annotate documentation improve and expand the man page to also mention the limitations of file annotations. Since people coming from the SVN/CVS world might first look here, also briefly advertise how the pickaxe interface makes it easy to go beyond these limitation. Signed-off-by: Jonas Fonseca <fonseca@diku.dk> Signed-off-by: Junio C Hamano <junkio@cox.net>
Jonas Fonseca committed
Aug 25, 2006 at 03:01 UTC
26e8c5d38543674173a37e4bb2096f836bd2ea2c
1 file changed
+23
-6
Documentation/git-blame.txt
+23
-6
@@ -3,21 +3,38 @@ git-blame(1)
3
4
NAME
5
----
6
-git-blame - Blame file lines on commits
6
+git-blame - Show what revision and author last modified each line of a file
7
8
SYNOPSIS
9
--------
10
-git-blame file [options] file [revision]
10
+'git-blame' [-c] [-l] [-t] [-S <revs-file>] [--] <file> [<rev>]
11
12
DESCRIPTION
13
-----------
14
-Annotates each line in the given file with information from the commit
15
-which introduced the line. Start annotation from the given revision.
14
+
15
+Annotates each line in the given file with information from the revision which
16
+last modified the line. Optionally, start annotating from the given revision.
17
+
18
+This report doesn't tell you anything about lines which have been deleted or
19
+replaced; you need to use a tool such as gitlink:git-diff[1] or the "pickaxe"
20
+interface briefly mentioned in the following paragraph.
21
+
22
+Apart from supporting file annotation, git also supports searching the
23
+development history for when a code snippet occured in a change. This makes it
24
+possible to track when a code snippet was added to a file, moved or copied
25
+between files, and eventually deleted or replaced. It works by searching for
26
+a text string in the diff. A small example:
27
+
28
+-----------------------------------------------------------------------------
29
+$ git log --pretty=oneline -S'blame_usage'
30
+5040f17eba15504bad66b14a645bddd9b015ebb7 blame -S <ancestry-file>
31
+ea4c7f9bf69e781dd0cd88d2bccb2bf5cc15c9a7 git-blame: Make the output
32
+-----------------------------------------------------------------------------
33
34
OPTIONS
35
-------
36
-c, --compatibility::
20
- Use the same output mode as git-annotate (Default: off).
37
+ Use the same output mode as gitlink:git-annotate[1] (Default: off).
38
39
-l, --long::
40
Show long rev (Default: off).
@@ -26,7 +43,7 @@ OPTIONS
43
Show raw timestamp (Default: off).
44
45
-S, --rev-file <revs-file>::
29
- Use revs from revs-file instead of calling git-rev-list.
46
+ Use revs from revs-file instead of calling gitlink:git-rev-list[1].
47
48
-h, --help::
49
Show help message.