-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtig.1.txt
160 lines (121 loc) · 4.75 KB
/
tig.1.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
tig(1)
======
NAME
----
tig - text-mode interface for git
SYNOPSIS
--------
[verse]
tig [options] [revisions] [--] [paths]
tig show [options] [revisions] [--] [paths]
tig blame [options] [rev] [--] path
tig status
tig < [git command output]
DESCRIPTION
-----------
Browse changes in a git repository. Additionally, tig(1) can also act
as a pager for output of various git commands.
When browsing repositories, tig(1) uses the underlying git commands
to present the user with various views, such as summarized commit log
and showing the commit with the log message, diffstat, and the diff.
Using tig(1) as a pager, it will display input from stdin and try
to colorize it.
OPTIONS
-------
Command line options recognized by tig include all valid git-log(1) and
git-diff(1) options, as well as the following subcommands and tig specific
options. The first command line parameter not starting with "-" is interpreted
as being either a revision specification or a path and will end the option
parsing. All following options will be passed untouched to the underlying git
command.
show::
Open diff view using the given git-show(1) options.
blame::
Show given file annotated by commits.
Takes zero or more git-blame(1) options.
Optionally limited from given revision.
status::
Start up in status view.
+<number>::
Show the first view with line <number> visible and selected.
-v, --version::
Show version and exit.
-h, --help::
Show help message and exit.
EXAMPLES
--------
Display the current branch:
-----------------------------------------------------------------------------
$ tig
-----------------------------------------------------------------------------
Display one or more specific branches:
-----------------------------------------------------------------------------
$ tig test master
-----------------------------------------------------------------------------
Display all branches:
-----------------------------------------------------------------------------
$ tig --all
-----------------------------------------------------------------------------
Display differences between two branches:
-----------------------------------------------------------------------------
$ tig test..master
-----------------------------------------------------------------------------
Display changes for a single file:
-----------------------------------------------------------------------------
$ tig -- README
-----------------------------------------------------------------------------
Display contents of the README file in a specific revision:
-----------------------------------------------------------------------------
$ tig show tig-0.8:README
-----------------------------------------------------------------------------
Display revisions between two dates for a specific file:
-----------------------------------------------------------------------------
$ tig --after="2004-01-01" --before="2006-05-16" -- README
-----------------------------------------------------------------------------
Blame file with copy detection enabled:
-----------------------------------------------------------------------------
$ tig blame -C README
-----------------------------------------------------------------------------
ENVIRONMENT VARIABLES
---------------------
In addition to environment variables used by git (e.g. GIT_DIR), tig defines
the ones below. The command related environment variables have access to the
internal state of tig via replacement variables, such as `%(commit)` and
`%(blob)`. See manpage:tigrc[5] for a full list.
TIGRC_USER::
Path of the user configuration file (defaults to `~/.tigrc`).
TIGRC_SYSTEM::
Path of the system wide configuration file (defaults to
`{sysconfdir}/tigrc`).
TIG_LS_REMOTE::
Set command for retrieving all repository references. The command
should output data in the same format as git-ls-remote(1).
TIG_DIFF_OPTS::
The diff options to use in the diff view. The diff view uses
git-show(1) for formatting and always passes --patch-with-stat.
TIG_TRACE::
Path for trace file where information about git commands are logged.
FILES
-----
'~/.tigrc'::
User configuration file. See manpage:tigrc[5] for examples.
'{sysconfdir}/tigrc'::
System wide configuration file.
'$GIT_DIR/config'::
'~/.gitconfig::
'{sysconfdir}/etc/gitconfig::
Git configuration files. Read on start-up with the help of
git-config(1).
include::BUGS[]
COPYRIGHT
---------
Copyright (c) 2006-2012 Jonas Fonseca <fonseca@diku.dk>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
SEE ALSO
--------
manpage:tigrc[5], manpage:tigmanual[7], git(7), gitk(1)
Online resources:
include::SITES[]