Fix status loading of unmerged entries to avoid access to freed memory
[tig] / tigrc.5.txt
1 tigrc(5)
2 ========
3
4 NAME
5 ----
6 tigrc - tig user configuration file
7
8
9 SYNOPSIS
10 --------
11 [verse]
12 .............................................................................
13 *set*   'variable' *=* 'value'
14 *bind*  'keymap' 'key' 'action'
15 *color* 'area' 'fgcolor' 'bgcolor' '[attributes]'
16 .............................................................................
17
18
19 DESCRIPTION
20 -----------
21
22 You can permanently set an option by putting it in the `~/.tigrc` file.  The
23 file consists of a series of 'commands'.  Each line of the file may contain
24 only one command.
25
26 The hash mark ('#') is used as a 'comment' character. All text after the
27 comment character to the end of the line is ignored. You can use comments to
28 annotate your initialization file.
29
30
31 Set command
32 -----------
33
34 A few selective variables can be configured via the set command. The syntax
35 is:
36
37 [verse]
38 ..............................................................................
39 *set* variables *=* value
40 ..............................................................................
41
42 Examples:
43
44 --------------------------------------------------------------------------
45 set show-author = yes           # Show author?
46 set show-date = yes             # Show commit date?
47 set show-rev-graph = yes        # Show revision graph?
48 set show-refs = yes             # Show references?
49 set show-line-numbers = no      # Show line numbers?
50 set author-width = 10           # Set width of the author column
51 set line-graphics = no          # Disable graphics characters
52 set line-number-interval = 5    # Interval between line numbers
53 set tab-size = 8                # Number of spaces per tab
54 set encoding = "UTF-8"          # Commit encoding
55 --------------------------------------------------------------------------
56
57 The type of variables are either bool, int, and string.
58
59 Valid bool values::
60
61         To set a bool variable to true use either "1", "true", or "yes".
62         Any other value will set the variable to false.
63
64 Valid int values::
65
66         A non-negative integer.
67
68 Valid string values::
69
70         A string of characters. Optionally, use either ' or " as delimiters.
71
72 Variables
73 ~~~~~~~~~
74
75 The following variables can be set:
76
77 'show-author' (bool)::
78 'show-date' (bool)::
79 'show-rev-graph' (bool)::
80 'show-refs' (bool)::
81
82         Whether to show author, date, revision graph, and references
83         (branches, tags, and remotes) in the main view on start-up. Can all be
84         toggled.
85
86 'author-width' (int)::
87
88         Width of the author column.
89
90 'line-graphics' (bool)::
91
92         Whether to use graphic characters for line drawing.
93
94 'line-number-interval' (int)::
95
96         Interval between line numbers. Note, you have to toggle on line
97         numbering with 'n' or the `-n` command line option.  The default is to
98         number every line.
99
100 'tab-size' (int)::
101
102         Number of spaces per tab. The default is 8 spaces.
103
104 'commit-encoding' (string)::
105
106         The encoding used for commits. The default is UTF-8. Not this option
107         is shadowed by the "i18n.commitencoding" option in `.git/config`.
108
109
110 Bind command
111 ------------
112
113 Using bind commands keys can be mapped to an action when pressed in a given
114 key map. The syntax is:
115
116 [verse]
117 ..............................................................................
118 *bind* 'keymap' 'key' 'action'
119 ..............................................................................
120
121 Examples:
122
123 --------------------------------------------------------------------------
124 # A few keybindings
125 bind main w scroll-line-up
126 bind main s scroll-line-down
127 bind main space enter
128 bind diff a previous
129 bind diff d next
130 bind diff b move-first-line
131 # 'unbind' the default quit key binding
132 bind main Q none
133 # An external command to update from upstream
134 bind generic F !git fetch
135 # Cherry-pick current commit onto current branch
136 bind generic C !git cherry-pick %(commit)
137 --------------------------------------------------------------------------
138
139 Keys are mapped by first searching the keybindings for the current view, then
140 the keybindings for the *generic* keymap, and last the default keybindings.
141 Thus, the view keybindings shadow the generic keybindings which Shadow the
142 built-in keybindings.
143
144 --
145
146 Keymaps::
147
148 Valid keymaps are: *main*, *diff*, *log*, *help*, *pager*, *status*, *stage*,
149 and *generic*.  Use *generic* to set key mapping in all keymaps.
150
151 Key values::
152
153 Key values should never be quoted. Use either the ASCII value or one of the
154 following symbolic key names. Symbolic key names are case insensitive, Use
155 *Hash* to bind to the `#` key, since the hash mark is used as a comment
156 character.
157
158 *Enter*, *Space*, *Backspace*, *Tab*, *Escape*, *Left*, *Right*, *Up*, *Down*,
159 *Insert*, *Delete*, *Hash*, *Home*, *End*, *PageUp*, *PageDown*, *F1*, *F2*, *F3*,
160 *F4*, *F5*, *F6*, *F7*, *F8*, *F9*, *F10*, *F11*, *F12*.
161
162 Action names::
163
164 Valid action names are described below. Note, all names are
165 case-insensitive, and you may use '-', '_', and '.' interchangeably,
166 e.g. "view-main", "View.Main", and "VIEW_MAIN" are the same.
167
168 --
169
170 Actions
171 ~~~~~~~
172
173 Apart from the action names listed below, all actions starting with a '!' will
174 be available as an external command. External commands can contain variable
175 names that will be substituted before the command is run. Valid variable names
176 are:
177
178 ifdef::backend-xhtml11[]
179 [frame="none"]
180 `-----------------------`-----------------------------------------------------
181 endif::backend-xhtml11[]
182 Browsing state variables
183 ------------------------------------------------------------------------------
184 %(head)                 The currently viewed 'head' ID. Defaults to HEAD
185 %(commit)               The currently selected commit ID.
186 %(blob)                 The currently selected blob ID.
187 %(directory)            The current directory path in the tree view; \
188                         empty for the root directory.
189 %(file)                 The currently selected file.
190 %(ref)                  The reference given to blame or HEAD if undefined.
191 ------------------------------------------------------------------------------
192
193 As an example, the following external command will save the current commit as
194 a patch file: "!git format-patch -1 %(commit)".
195
196 ifdef::backend-xhtml11[]
197 [frame="none"]
198 `-----------------------`-----------------------------------------------------
199 endif::backend-xhtml11[]
200 View switching:
201 ------------------------------------------------------------------------------
202 view-main               Show main view
203 view-diff               Show diff view
204 view-log                Show log view
205 view-tree               Show tree view
206 view-blob               Show blob view
207 view-blame              Show blame view
208 view-status             Show status view
209 view-stage              Show stage view
210 view-pager              Show pager view
211 view-help               Show help page
212 ------------------------------------------------------------------------------
213
214 ifdef::backend-xhtml11[]
215 [frame="none"]
216 `-----------------------`-----------------------------------------------------
217 endif::backend-xhtml11[]
218 View manipulation:
219 ------------------------------------------------------------------------------
220 enter                   Enter current line and scroll
221 next                    Move to next
222 previous                Move to previous
223 view-next               Move focus to next view
224 refresh                 Reload and refresh view
225 maximize                Maximize the current view
226 view-close              Close the current view
227 quit                    Close all views and quit
228 ------------------------------------------------------------------------------
229
230 ifdef::backend-xhtml11[]
231 [frame="none"]
232 `-----------------------`-----------------------------------------------------
233 endif::backend-xhtml11[]
234 Cursor navigation:
235 ------------------------------------------------------------------------------
236 move-up                 Move cursor one line up
237 move-down               Move cursor one line down
238 move-page-down          Move cursor one page down
239 move-page-up            Move cursor one page up
240 move-first-line         Move cursor to first line
241 move-last-line          Move cursor to last line
242 ------------------------------------------------------------------------------
243
244 ifdef::backend-xhtml11[]
245 [frame="none"]
246 `-----------------------`-----------------------------------------------------
247 endif::backend-xhtml11[]
248 Scrolling:
249 ------------------------------------------------------------------------------
250 scroll-line-up          Scroll one line up
251 scroll-line-down        Scroll one line down
252 scroll-page-eup         Scroll one page up
253 scroll-page-down        Scroll one page down
254 ------------------------------------------------------------------------------
255
256 ifdef::backend-xhtml11[]
257 [frame="none"]
258 `-----------------------`-----------------------------------------------------
259 endif::backend-xhtml11[]
260 Searching:
261 ------------------------------------------------------------------------------
262 search                  Search the view
263 search-back             Search backwards in the view
264 find-next               Find next search match
265 find-prev               Find previous search match
266 ------------------------------------------------------------------------------
267
268 ifdef::backend-xhtml11[]
269 [frame="none"]
270 `-----------------------`-----------------------------------------------------
271 endif::backend-xhtml11[]
272 Misc:
273 ------------------------------------------------------------------------------
274 none                    Do nothing
275 prompt                  Bring up the prompt
276 screen-redraw           Redraw the screen
277 screen-resize           Resize the screen
278 show-version            Show version information
279 stop-loading            Stop all loading views
280 toggle-lineno           Toggle line numbers
281 toggle-date             Toggle date display
282 toggle-author           Toggle author display
283 toggle-rev-graph        Toggle revision graph visualization
284 toggle-refs             Toggle reference display
285 status-update           Update file status
286 status-merge            Resolve unmerged file
287 stage-next              Find next chunk to stage
288 tree-parent             Switch to parent directory in tree view
289 edit                    Open in editor
290 ------------------------------------------------------------------------------
291
292
293 Color command
294 -------------
295
296 Color commands control highlighting and the user interface styles. If your
297 terminal supports color, these commands can be used to assign foreground and
298 background combinations to certain areas. Optionally, an attribute can be
299 given as the last parameter. The syntax is:
300
301 [verse]
302 ..............................................................................
303 *color* 'area' 'fgcolor' 'bgcolor' '[attributes]'
304 ..............................................................................
305
306 Examples:
307
308 ------------------------------------------------------------------------------
309 # Overwrite the default terminal colors to white on black.
310 color default           white   black
311 # Diff colors
312 color diff-header       yellow  default
313 color diff-index        blue    default
314 color diff-chunk        magenta default
315 # A strange looking cursor line
316 color cursor            red     default underline
317 # UI colors
318 color title-blur        white   blue
319 color title-focus       white   blue    bold
320 ------------------------------------------------------------------------------
321
322 Area names::
323
324         Valid area names are described below. Note, all names are
325         case-insensitive, and you may use '-', '_', and '.' interchangeably,
326         e.g. "Diff-Header", "DIFF_HEADER", and "diff.header" are the same.
327
328 Color names::
329
330         Valid colors include: *white*, *black*, *green*, *magenta*, *blue*,
331         *cyan*, *yellow*, *red*, *default*. Use *default* to refer to the
332         default terminal colors. This is recommended for background colors
333         if you are using a terminal with a transparent background.
334
335 Attribute names::
336
337         Valid attributes include: *normal*, *blink*, *bold*, *dim*, *reverse*,
338         *standout*, and *underline*. Note, not all attributes may be supported
339         by the terminal.
340
341 UI colors
342 ~~~~~~~~~
343
344 The colors and attributes to be used for the text that is not highlighted or
345 that specify the use of the default terminal colors can be controlled by
346 setting the *default* color option.
347
348 ifdef::backend-xhtml11[]
349 [frame="none"]
350 `-----------------------`-----------------------------------------------------
351 endif::backend-xhtml11[]
352 General:
353 ------------------------------------------------------------------------------
354 default                 Overwrite default terminal colors (see above).
355 cursor                  The cursor line.
356 status                  The status window showing info messages.
357 title-focus             The title window for the current view.
358 title-blur              The title window of any backgrounded view.
359 delimiter               Delimiter shown for truncated lines.
360 line-number             Line numbers.
361 date                    The commit date.
362 ------------------------------------------------------------------------------
363
364 ifdef::backend-xhtml11[]
365 [frame="none"]
366 `-----------------------`-----------------------------------------------------
367 endif::backend-xhtml11[]
368 Main view colors:
369 ------------------------------------------------------------------------------
370 main-author             The commit author.
371 main-revgraph           The revision graph.
372 main-commit             The commit comment.
373 main-head               Label of the current branch.
374 main-remote             Label of a remote.
375 main-tracked            Label of the remote tracked by the current branch.
376 main-tag                Label of a signed tag.
377 main-local-tag          Label of a local tag.
378 main-ref                Label of any other reference.
379 ------------------------------------------------------------------------------
380
381 ifdef::backend-xhtml11[]
382 [frame="none"]
383 `-----------------------`-----------------------------------------------------
384 endif::backend-xhtml11[]
385 Status view:
386 ------------------------------------------------------------------------------
387 stat-head               The "On branch"-line.
388 stat-section            Status section titles,
389 stat-staged             Status flag of staged files.
390 stat-unstaged           Status flag of unstaged files.
391 stat-untracked          Status flag of untracked files.
392 ------------------------------------------------------------------------------
393
394 ifdef::backend-xhtml11[]
395 [frame="none"]
396 `-----------------------`-----------------------------------------------------
397 endif::backend-xhtml11[]
398 Blame view:
399 ------------------------------------------------------------------------------
400 blame-id                The commit ID.
401 ------------------------------------------------------------------------------
402
403 Highlighting
404 ~~~~~~~~~~~~
405
406 --
407
408 Diff markup::
409
410 Options concerning diff start, chunks and lines added and deleted.
411
412 *diff-header*, *diff-chunk*, *diff-add*, *diff-del*
413
414 Enhanced git diff markup::
415
416 Extra diff information emitted by the git diff machinery, such as mode
417 changes, rename detection, and similarity.
418
419 *diff-oldmode*, *diff-newmode*, *diff-copy-from*, *diff-copy-to*,
420 *diff-rename-from*, *diff-rename-to*, *diff-similarity*, *diff-dissimilarity*
421 *diff-tree*, *diff-index*
422
423 Pretty print commit headers::
424
425 Commit diffs and the revision logs are usually formatted using pretty printed
426 headers , unless `--pretty=raw` was given. This includes lines, such as merge
427 info, commit ID, and author and committer date.
428
429 *pp-author*, *pp-commit*, *pp-merge*, *pp-date*, *pp-adate*, *pp-cdate*,
430 *pp-refs*
431
432 Raw commit header::
433
434 Usually shown when `--pretty=raw` is given, however 'commit' is pretty much
435 omnipresent.
436
437 *commit*, *parent*, *tree*, *author*, *committer*
438
439 Commit message::
440
441 For now only `Signed-off-by` and `Acked-by` lines are colorized.
442
443 *signoff*, *acked*
444
445 Tree markup::
446
447 Colors for information of the tree view.
448
449 *tree-dir*, *tree-file*
450
451 --
452
453 COPYRIGHT
454 ---------
455 Copyright (c) 2006-2009 Jonas Fonseca <fonseca@diku.dk>
456
457 Licensed under the terms of the GNU General Public License.
458
459 SEE ALSO
460 --------
461 manpage:tig[1] and the http://jonas.nitro.dk/tig/manual.html[tig manual].