Sync docs
[tig] / tig.1.html
CommitLineData
2b9c2ad0
JF
1<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"\r
2 "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">\r
3<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">\r
4<head>\r
5<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />\r
6<meta name="generator" content="AsciiDoc 7.0.2" />\r
7<style type="text/css">\r
8/* Debug borders */\r
9p, li, dt, dd, div, pre, h1, h2, h3, h4, h5, h6 {\r
10/*\r
11 border: 1px solid red;\r
12*/\r
13}\r
14\r
15body {\r
16 margin: 1em 5% 1em 5%;\r
17}\r
18\r
19a { color: blue; }\r
20a:visited { color: fuchsia; }\r
21\r
22em {\r
23 font-style: italic;\r
24}\r
25\r
26strong {\r
27 font-weight: bold;\r
28}\r
29\r
30tt {\r
31 color: navy;\r
32}\r
33\r
34h1, h2, h3, h4, h5, h6 {\r
35 color: #527bbd;\r
36 font-family: sans-serif;\r
37 margin-top: 1.2em;\r
38 margin-bottom: 0.5em;\r
39 line-height: 1.3;\r
40}\r
41\r
42h1 {\r
43 border-bottom: 2px solid silver;\r
44}\r
45h2 {\r
46 border-bottom: 2px solid silver;\r
47 padding-top: 0.5em;\r
48}\r
49\r
50div.sectionbody {\r
51 font-family: serif;\r
52 margin-left: 0;\r
53}\r
54\r
55hr {\r
56 border: 1px solid silver;\r
57}\r
58\r
59p {\r
60 margin-top: 0.5em;\r
61 margin-bottom: 0.5em;\r
62}\r
63\r
64pre {\r
65 padding: 0;\r
66 margin: 0;\r
67}\r
68\r
69span#author {\r
70 color: #527bbd;\r
71 font-family: sans-serif;\r
72 font-weight: bold;\r
73 font-size: 1.2em;\r
74}\r
75span#email {\r
76}\r
77span#revision {\r
78 font-family: sans-serif;\r
79}\r
80\r
81div#footer {\r
82 font-family: sans-serif;\r
83 font-size: small;\r
84 border-top: 2px solid silver;\r
85 padding-top: 0.5em;\r
86 margin-top: 4.0em;\r
87}\r
88div#footer-text {\r
89 float: left;\r
90 padding-bottom: 0.5em;\r
91}\r
92div#footer-badges {\r
93 float: right;\r
94 padding-bottom: 0.5em;\r
95}\r
96\r
97div#preamble,\r
98div.tableblock, div.imageblock, div.exampleblock, div.verseblock,\r
99div.quoteblock, div.literalblock, div.listingblock, div.sidebarblock,\r
100div.admonitionblock {\r
101 margin-right: 10%;\r
102 margin-top: 1.5em;\r
103 margin-bottom: 1.5em;\r
104}\r
105div.admonitionblock {\r
106 margin-top: 2.5em;\r
107 margin-bottom: 2.5em;\r
108}\r
109\r
110div.content { /* Block element content. */\r
111 padding: 0;\r
112}\r
113\r
114/* Block element titles. */\r
115div.title, caption.title {\r
116 font-family: sans-serif;\r
117 font-weight: bold;\r
118 text-align: left;\r
119 margin-top: 1.0em;\r
120 margin-bottom: 0.5em;\r
121}\r
122div.title + * {\r
123 margin-top: 0;\r
124}\r
125\r
126td div.title:first-child {\r
127 margin-top: 0.0em;\r
128}\r
129div.content div.title:first-child {\r
130 margin-top: 0.0em;\r
131}\r
132div.content + div.title {\r
133 margin-top: 0.0em;\r
134}\r
135\r
136div.sidebarblock > div.content {\r
137 background: #ffffee;\r
138 border: 1px solid silver;\r
139 padding: 0.5em;\r
140}\r
141\r
142div.listingblock > div.content {\r
143 border: 1px solid silver;\r
144 background: #f4f4f4;\r
145 padding: 0.5em;\r
146}\r
147\r
148div.quoteblock > div.content {\r
149 padding-left: 2.0em;\r
150}\r
151div.quoteblock .attribution {\r
152 text-align: right;\r
153}\r
154\r
155div.admonitionblock .icon {\r
156 vertical-align: top;\r
157 font-size: 1.1em;\r
158 font-weight: bold;\r
159 text-decoration: underline;\r
160 color: #527bbd;\r
161 padding-right: 0.5em;\r
162}\r
163div.admonitionblock td.content {\r
164 padding-left: 0.5em;\r
165 border-left: 2px solid silver;\r
166}\r
167\r
168div.exampleblock > div.content {\r
169 border-left: 2px solid silver;\r
170 padding: 0.5em;\r
171}\r
172\r
173div.verseblock div.content {\r
174 white-space: pre;\r
175}\r
176\r
177div.imageblock div.content { padding-left: 0; }\r
178div.imageblock img { border: 1px solid silver; }\r
179span.image img { border-style: none; }\r
180\r
181dl {\r
182 margin-top: 0.8em;\r
183 margin-bottom: 0.8em;\r
184}\r
185dt {\r
186 margin-top: 0.5em;\r
187 margin-bottom: 0;\r
188 font-style: italic;\r
189}\r
190dd > *:first-child {\r
191 margin-top: 0;\r
192}\r
193\r
194ul, ol {\r
195 list-style-position: outside;\r
196}\r
197ol.olist2 {\r
198 list-style-type: lower-alpha;\r
199}\r
200\r
201div.tableblock > table {\r
202 border-color: #527bbd;\r
203 border-width: 3px;\r
204}\r
205thead {\r
206 font-family: sans-serif;\r
207 font-weight: bold;\r
208}\r
209tfoot {\r
210 font-weight: bold;\r
211}\r
212\r
213div.hlist {\r
214 margin-top: 0.8em;\r
215 margin-bottom: 0.8em;\r
216}\r
217td.hlist1 {\r
218 vertical-align: top;\r
219 font-style: italic;\r
220 padding-right: 0.8em;\r
221}\r
222td.hlist2 {\r
223 vertical-align: top;\r
224}\r
225\r
226@media print {\r
227 div#footer-badges { display: none; }\r
228}\r
229include::./stylesheets/xhtml11-manpage.css[]\r
230/* Workarounds for IE6's broken and incomplete CSS2. */\r
231\r
232div.sidebar-content {\r
233 background: #ffffee;\r
234 border: 1px solid silver;\r
235 padding: 0.5em;\r
236}\r
237div.sidebar-title, div.image-title {\r
238 font-family: sans-serif;\r
239 font-weight: bold;\r
240 margin-top: 0.0em;\r
241 margin-bottom: 0.5em;\r
242}\r
243\r
244div.listingblock div.content {\r
245 border: 1px solid silver;\r
246 background: #f4f4f4;\r
247 padding: 0.5em;\r
248}\r
249\r
250div.quoteblock-content {\r
251 padding-left: 2.0em;\r
252}\r
253\r
254div.exampleblock-content {\r
255 border-left: 2px solid silver;\r
256 padding-left: 0.5em;\r
257}\r
258</style>\r
259<title>TIG(1)</title>\r
260</head>\r
261<body>\r
262<div id="header">\r
263<h1>\r
264TIG(1) Manual Page\r
265</h1>\r
266<h2>NAME</h2>\r
267<div class="sectionbody">\r
268<p>tig -\r
269 text-mode interface for git\r
270</p>\r
271</div>\r
272</div>\r
273<h2>SYNOPSIS</h2>\r
274<div class="sectionbody">\r
275<div class="verseblock">\r
276<div class="content">tig [options]\r
277tig [options] [--] [git log options]\r
278tig [options] log [git log options]\r
279tig [options] diff [git diff options]\r
280tig [options] show [git show options]\r
281tig [options] &lt; [git command output]</div></div>\r
282</div>\r
283<h2>DESCRIPTION</h2>\r
284<div class="sectionbody">\r
285<p>Browse changes in a git repository. Additionally, tig(1) can also act\r
286as a pager for output of various git commands.</p>\r
287<p>When browsing repositories, tig(1) uses the underlying git commands\r
288to present the user with various views, such as summarized commit log\r
289and showing the commit with the log message, diffstat, and the diff.</p>\r
290<p>Using tig(1) as a pager, it will display input from stdin and try\r
291to colorize it.</p>\r
292</div>\r
293<h2>OPTIONS</h2>\r
294<div class="sectionbody">\r
295<dl>\r
296<dt>\r
297-l\r
298</dt>\r
299<dd>\r
300<p>\r
301 Start up in log view using the internal log command.\r
302</p>\r
303</dd>\r
304<dt>\r
305-d\r
306</dt>\r
307<dd>\r
308<p>\r
309 Start up in diff view using the internal diff command.\r
310</p>\r
311</dd>\r
312<dt>\r
313-n[INTERVAL], --line-number[=INTERVAL]\r
314</dt>\r
315<dd>\r
316<p>\r
317 Prefix line numbers in log and diff view.\r
318 Optionally, with interval different than each line.\r
319</p>\r
320</dd>\r
321<dt>\r
322-t[NSPACES], --tab-size[=NSPACES]\r
323</dt>\r
324<dd>\r
325<p>\r
326 Set the number of spaces tabs should be expanded to.\r
327</p>\r
328</dd>\r
329<dt>\r
330-v, --version\r
331</dt>\r
332<dd>\r
333<p>\r
334 Show version and exit.\r
335</p>\r
336</dd>\r
337<dt>\r
338--\r
339</dt>\r
340<dd>\r
341<p>\r
342 End of tig(1) options. Useful when specifying command\r
343 options for the main view. Example:\r
344</p>\r
345<div class="literalblock">\r
346<div class="content">\r
347<pre><tt>$ tig -- --since=1.month</tt></pre>\r
348</div></div>\r
349</dd>\r
350<dt>\r
351log [git log options]\r
352</dt>\r
353<dd>\r
354<p>\r
355 Open log view using the given git log options.\r
356</p>\r
357</dd>\r
358<dt>\r
359diff [git diff options]\r
360</dt>\r
361<dd>\r
362<p>\r
363 Open diff view using the given git diff options.\r
364</p>\r
365</dd>\r
366<dt>\r
367show [git show options]\r
368</dt>\r
369<dd>\r
370<p>\r
371 Open diff view using the given git show options.\r
372</p>\r
373</dd>\r
374<dt>\r
375[git log options]\r
376</dt>\r
377<dd>\r
378<p>\r
379 tig(1) will stop the option parsing when the first\r
380 command line parameter not starting with "-" is\r
381 encountered. All options including this one will be\r
382 passed to git log when loading the main view.\r
383 This makes it possible to say:\r
384</p>\r
385<div class="literalblock">\r
386<div class="content">\r
387<pre><tt>$ tig tag-1.0..HEAD</tt></pre>\r
388</div></div>\r
389</dd>\r
390</dl>\r
391<h3>Pager mode</h3>\r
392<p>If stdin is a pipe, any log or diff options will be ignored and the\r
393pager view will be opened loading data from stdin. The pager mode\r
394can be used for colorizing output from various git commands.</p>\r
395<p>Example on how to colorize the output of git-show(1):</p>\r
396<div class="literalblock">\r
397<div class="content">\r
398<pre><tt>$ git show | tig</tt></pre>\r
399</div></div>\r
400<h3>Git command options</h3>\r
401<p>All git command options specified on the command line will\r
402be passed to the given command and all will be shell quoted\r
403before they are passed to the shell.</p>\r
404<div class="admonitionblock">\r
405<table><tr>\r
406<td class="icon">\r
407<div class="title">Note</div>\r
408</td>\r
409<td class="content">If you specify options for the main view, you should\r
410not use the <tt>--pretty</tt> option as this option will be set\r
411automatically to the format expected by the main view.</td>\r
412</tr></table>\r
413</div>\r
414<p>Example on how to open the log view and show both author and\r
415committer information:</p>\r
416<div class="literalblock">\r
417<div class="content">\r
418<pre><tt>$ tig log --pretty=fuller</tt></pre>\r
419</div></div>\r
420<p>See the <a href="#refspec">"Specifying revisions"</a> section below\r
421for an introduction to revision options supported by the git\r
422commands. For details on specific git command options, refer\r
423to the man page of the command in question.</p>\r
424</div>\r
425<h2>ENVIRONMENT VARIABLES</h2>\r
426<div class="sectionbody">\r
427<p>Several options related to the interface with git can be configured\r
428via environment options.</p>\r
429<h3>Repository references</h3>\r
430<p>Commits that are referenced by tags and branch heads will be marked\r
431by the reference name surrounded by <em>[</em> and <em>]</em>:</p>\r
432<div class="literalblock">\r
433<div class="content">\r
434<pre><tt>2006-03-26 19:42 Petr Baudis | [cogito-0.17.1] Cogito 0.17.1</tt></pre>\r
435</div></div>\r
436<p>If you want to filter out certain directories under <tt>.git/refs/</tt>, say\r
437<tt>tmp</tt> you can do it by setting the following variable:</p>\r
438<div class="literalblock">\r
439<div class="content">\r
440<pre><tt>$ TIG_LS_REMOTE="git ls-remote . | sed /\/tmp\//d" tig</tt></pre>\r
441</div></div>\r
442<p>Or set the variable permanently in your environment.</p>\r
443<dl>\r
444<dt>\r
445TIG_LS_REMOTE\r
446</dt>\r
447<dd>\r
448<p>\r
449 Set command for retrieving all repository references. The command\r
450 should output data in the same format as git-ls-remote(1).\r
451</p>\r
452</dd>\r
453</dl>\r
454<h3><a id="view-commands"></a>View commands</h3>\r
455<p>It is possible to alter which commands are used for the different views.\r
456If for example you prefer commits in the main view to be sorted by date\r
457and only show 500 commits, use:</p>\r
458<div class="literalblock">\r
459<div class="content">\r
460<pre><tt>$ TIG_MAIN_CMD="git log --date-order -n500 --pretty=raw %s" tig</tt></pre>\r
461</div></div>\r
462<p>Or set the variable permanently in your environment.</p>\r
463<p>Notice, how <tt>%s</tt> is used to specify the commit reference. There can\r
464be a maximum of 5 <tt>%s</tt> ref specifications.</p>\r
465<dl>\r
466<dt>\r
467TIG_DIFF_CMD\r
468</dt>\r
469<dd>\r
470<p>\r
471 The command used for the diff view. By default, git show is used\r
472 as a backend.\r
473</p>\r
474</dd>\r
475<dt>\r
476TIG_LOG_CMD\r
477</dt>\r
478<dd>\r
479<p>\r
480 The command used for the log view. If you prefer to have both\r
481 author and committer shown in the log view be sure to pass\r
482 <tt>--pretty=fuller</tt> to git log.\r
483</p>\r
484</dd>\r
485<dt>\r
486TIG_MAIN_CMD\r
487</dt>\r
488<dd>\r
489<p>\r
490 The command used for the main view. Note, you must always specify\r
491 the option: <tt>--pretty=raw</tt> since the main view parser expects to\r
492 read that format.\r
493</p>\r
494</dd>\r
495</dl>\r
496</div>\r
497<h2>The viewer</h2>\r
498<div class="sectionbody">\r
499<p>tig(1) presents various <em>views</em> of a repository. Each view is based on output\r
500from an external command, most often <em>git log</em>, <em>git diff</em>, or <em>git show</em>.</p>\r
501<dl>\r
502<dt>\r
503The main view\r
504</dt>\r
505<dd>\r
506<p>\r
507 Is the default view, and it shows a one line summary of each commit\r
508 in the chosen list of revision. The summary includes commit date,\r
509 author, and the first line of the log message. Additionally, any\r
510 repository references, such as tags, will be shown.\r
511</p>\r
512</dd>\r
513<dt>\r
514The log view\r
515</dt>\r
516<dd>\r
517<p>\r
518 Presents a more rich view of the revision log showing the whole log\r
519 message and the diffstat.\r
520</p>\r
521</dd>\r
522<dt>\r
523The diff view\r
524</dt>\r
525<dd>\r
526<p>\r
527 Shows either the diff of the current working tree, that is, what\r
528 has changed since the last commit, or the commit diff complete\r
529 with log message, diffstat and diff.\r
530</p>\r
531</dd>\r
532<dt>\r
533The pager view\r
534</dt>\r
535<dd>\r
536<p>\r
537 Is used for displaying both input from stdin and output from git\r
538 commands entered in the internal prompt.\r
539</p>\r
540</dd>\r
541<dt>\r
542The help view\r
543</dt>\r
544<dd>\r
545<p>\r
546 Displays the information from the tig(1) man page. For the help view\r
547 to work you need to have the tig(1) man page installed.\r
548</p>\r
549</dd>\r
550</dl>\r
551</div>\r
552<h2>KEYS</h2>\r
553<div class="sectionbody">\r
554<p>Below the default key bindings are shown.</p>\r
555<h3>View switching</h3>\r
556<dl>\r
557<dt>\r
558m\r
559</dt>\r
560<dd>\r
561<p>\r
562 Switch to main view.\r
563</p>\r
564</dd>\r
565<dt>\r
566d\r
567</dt>\r
568<dd>\r
569<p>\r
570 Switch to diff view.\r
571</p>\r
572</dd>\r
573<dt>\r
574l\r
575</dt>\r
576<dd>\r
577<p>\r
578 Switch to log view.\r
579</p>\r
580</dd>\r
581<dt>\r
582p\r
583</dt>\r
584<dd>\r
585<p>\r
586 Switch to pager view.\r
587</p>\r
588</dd>\r
589<dt>\r
590h\r
591</dt>\r
592<dd>\r
593<p>\r
594 Show man page.\r
595</p>\r
596</dd>\r
597<dt>\r
598Return\r
599</dt>\r
600<dd>\r
601<p>\r
602 If on a commit line show the commit diff. Additionally, if in\r
603 main or log view this will split the view. To open the commit\r
604 diff in full size view either use <em>d</em> or press Return twice.\r
605</p>\r
606</dd>\r
607<dt>\r
608Tab\r
609</dt>\r
610<dd>\r
611<p>\r
612 Switch to next view.\r
613</p>\r
614</dd>\r
615</dl>\r
616<h3>Cursor navigation</h3>\r
617<dl>\r
618<dt>\r
619Up\r
620</dt>\r
621<dd>\r
622<p>\r
623 Move cursor one line up.\r
624</p>\r
625</dd>\r
626<dt>\r
627Down\r
628</dt>\r
629<dd>\r
630<p>\r
631 Move cursor one line down.\r
632</p>\r
633</dd>\r
634<dt>\r
635k\r
636</dt>\r
637<dd>\r
638<p>\r
639 Move cursor one line up and enter. When used in the main view\r
640 this will always show the diff of the current commit in the\r
641 split diff view.\r
642</p>\r
643</dd>\r
644<dt>\r
645j\r
646</dt>\r
647<dd>\r
648<p>\r
649 Move cursor one line down and enter.\r
650</p>\r
651</dd>\r
652<dt>\r
653PgUp\r
654</dt>\r
655<dd>\r
656<p>\r
657 Move cursor one page up.\r
658</p>\r
659</dd>\r
660<dt>\r
661PgDown\r
662</dt>\r
663<dd>\r
664<p>\r
665 Move cursor one page down.\r
666</p>\r
667</dd>\r
668<dt>\r
669Home\r
670</dt>\r
671<dd>\r
672<p>\r
673 Jump to first line.\r
674</p>\r
675</dd>\r
676<dt>\r
677End\r
678</dt>\r
679<dd>\r
680<p>\r
681 Jump to last line.\r
682</p>\r
683</dd>\r
684</dl>\r
685<h3>Scrolling</h3>\r
686<dl>\r
687<dt>\r
688Insert\r
689</dt>\r
690<dd>\r
691<p>\r
692 Scroll view one line up.\r
693</p>\r
694</dd>\r
695<dt>\r
696Delete\r
697</dt>\r
698<dd>\r
699<p>\r
700 Scroll view one line down.\r
701</p>\r
702</dd>\r
703<dt>\r
704w\r
705</dt>\r
706<dd>\r
707<p>\r
708 Scroll view one page up.\r
709</p>\r
710</dd>\r
711<dt>\r
712s\r
713</dt>\r
714<dd>\r
715<p>\r
716 Scroll view one page down.\r
717</p>\r
718</dd>\r
719</dl>\r
720<h3>Misc</h3>\r
721<dl>\r
722<dt>\r
723q\r
724</dt>\r
725<dd>\r
726<p>\r
727 Quit\r
728</p>\r
729</dd>\r
730<dt>\r
731r\r
732</dt>\r
733<dd>\r
734<p>\r
735 Redraw screen.\r
736</p>\r
737</dd>\r
738<dt>\r
739z\r
740</dt>\r
741<dd>\r
742<p>\r
743 Stop all background loading. This can be useful if you use\r
744 tig(1) in a repository with a long history without limiting\r
745 the revision log.\r
746</p>\r
747</dd>\r
748<dt>\r
749v\r
750</dt>\r
751<dd>\r
752<p>\r
753 Show version.\r
754</p>\r
755</dd>\r
756<dt>\r
757n\r
758</dt>\r
759<dd>\r
760<p>\r
761 Toggle line numbers on/off.\r
762</p>\r
763</dd>\r
764<dt>\r
765<em>:</em>\r
766</dt>\r
767<dd>\r
768<p>\r
769 Open prompt. This allows you to specify what git command\r
770 to run. Example:\r
771</p>\r
772<div class="literalblock">\r
773<div class="content">\r
774<pre><tt>:log -p</tt></pre>\r
775</div></div>\r
776</dd>\r
777</dl>\r
778</div>\r
395d626e 779<h2><a id="refspec"></a>Revision specification</h2>\r
2b9c2ad0
JF
780<div class="sectionbody">\r
781<p>This section describes various ways to specify what revisions to display\r
395d626e
JF
782or otherwise limit the view to. tig(1) does not itself parse the described\r
783revision options so refer to the relevant git man pages for futher\r
784information. Relevant man pages besides git-log(1) are git-diff(1) and\r
785git-rev-list(1).</p>\r
786<p>You can tune the interaction with git by making use of the options\r
787explained in this section. For example, by configuring the environment\r
788variables described in the <a href="#view-commands">"View commands"</a> section.</p>\r
789<h3>Limit by path name</h3>\r
2b9c2ad0
JF
790<p>If you are interested only in those revisions that made changes to a\r
791specific file (or even several files) list the files like this:</p>\r
792<div class="literalblock">\r
793<div class="content">\r
794<pre><tt>$ tig log Makefile</tt></pre>\r
795</div></div>\r
796<p>To avoid ambiguity with repository references such as tag name, be sure\r
797to separate file names from other git options using "--". So if you\r
798have a file named <em>master</em> it will clash with the reference named\r
799<em>master</em>, and thus you will have to use:</p>\r
800<div class="literalblock">\r
801<div class="content">\r
56235576 802<pre><tt>$ tig log -- master</tt></pre>\r
2b9c2ad0
JF
803</div></div>\r
804<div class="admonitionblock">\r
805<table><tr>\r
806<td class="icon">\r
807<div class="title">Note</div>\r
808</td>\r
809<td class="content">For the main view, avoiding ambiguity will in some cases require\r
810you to specify two "--" options. The first will make tig(1) stop\r
811option processing and the latter will be passed to git log.</td>\r
812</tr></table>\r
813</div>\r
814<h3>Limit by date or number</h3>\r
815<p>To speed up interaction with git, you can limit the amount of commits\r
816to show both for the log and main view. Either limit by date using\r
817e.g. <tt>--since=1.month</tt> or limit by the number of commits using <tt>-n400</tt>.</p>\r
395d626e
JF
818<p>If you are only interested in changed that happened between two dates\r
819you can use:</p>\r
820<div class="literalblock">\r
821<div class="content">\r
56235576 822<pre><tt>$ tig -- --after=May.5th --before=2006-05-16.15:44</tt></pre>\r
395d626e 823</div></div>\r
2b9c2ad0
JF
824<div class="admonitionblock">\r
825<table><tr>\r
826<td class="icon">\r
827<div class="title">Note</div>\r
828</td>\r
395d626e 829<td class="content">The dot (".") is used as a separator instead of a space to avoid\r
56235576
JF
830having to quote the option value. If you prefer use <tt>--after="May 5th"</tt>\r
831instead of <tt>--after="May 5th"</tt>.</td>\r
2b9c2ad0
JF
832</tr></table>\r
833</div>\r
395d626e 834<h3>Limiting by commit ranges</h3>\r
2b9c2ad0
JF
835<p>Alternatively, commits can be limited to a specific range, such as\r
836"all commits between <em>tag-1.0</em> and <em>tag-2.0</em>". For example:</p>\r
837<div class="literalblock">\r
838<div class="content">\r
839<pre><tt>$ tig log tag-1.0..tag-2.0</tt></pre>\r
840</div></div>\r
841<p>This way of commit limiting makes it trivial to only browse the commits\r
842which haven't been pushed to a remote branch. Assuming <em>origin</em> is your\r
843upstream remote branch, using:</p>\r
844<div class="literalblock">\r
845<div class="content">\r
846<pre><tt>$ tig log origin..HEAD</tt></pre>\r
847</div></div>\r
848<p>will list what will be pushed to the remote branch. Optionally, the ending\r
849<em>HEAD</em> can be left out since it is implied.</p>\r
850<h3>Limiting by reachability</h3>\r
851<p>Git interprets the range specifier "tag-1.0..tag-2.0" as\r
852"all commits reachable from <em>tag-2.0</em> but not from <em>tag-1.0</em>".\r
395d626e
JF
853Where reachability refers to what commits are ancestors (or part of the\r
854history) of the branch or tagged revision in question.</p>\r
855<p>If you prefer to specify which commit to preview in this way use the\r
2b9c2ad0
JF
856following:</p>\r
857<div class="literalblock">\r
858<div class="content">\r
859<pre><tt>$ tig log tag-2.0 ^tag-1.0</tt></pre>\r
860</div></div>\r
861<p>You can think of <em>^</em> as a negation operator. Using this alternate syntax,\r
862it is possible to further prune commits by specifying multiple branch\r
863cut offs.</p>\r
395d626e
JF
864<h3>Combining revisions specification</h3>\r
865<p>Revisions options can to some degree be combined, which makes it possible\r
866to say "show at most 20 commits from within the last month that changed\r
867files under the Documentation/ directory."</p>\r
868<div class="literalblock">\r
869<div class="content">\r
870<pre><tt>$ tig -- --since=1.month -n20 -- Documentation/</tt></pre>\r
871</div></div>\r
872<h3>Examining all repository references</h3>\r
873<p>In some cases, it can be useful to query changes across all references\r
874in a repository. An example is to ask "did any line of development in\r
875this repository change a particular file within the last week". This\r
876can be accomplished using:</p>\r
877<div class="literalblock">\r
878<div class="content">\r
879<pre><tt>$ tig -- --all --since=1.week -- Makefile</tt></pre>\r
880</div></div>\r
2b9c2ad0
JF
881</div>\r
882<h2>BUGS</h2>\r
883<div class="sectionbody">\r
884<p>Known bugs and problems:</p>\r
885<ul>\r
886<li>\r
887<p>\r
888If the screen width is very small the main view can draw\r
889outside the current view causing bad wrapping. Same goes\r
890for title and status windows.\r
891</p>\r
892</li>\r
893</ul>\r
894</div>\r
895<h2>TODO</h2>\r
896<div class="sectionbody">\r
897<p>Features that should be explored.</p>\r
898<ul>\r
899<li>\r
900<p>\r
901Searching.\r
902</p>\r
903</li>\r
904<li>\r
905<p>\r
906Locale support.\r
907</p>\r
908</li>\r
909</ul>\r
910</div>\r
911<h2>COPYRIGHT</h2>\r
912<div class="sectionbody">\r
913<p>Copyright (c) Jonas Fonseca &lt;fonseca@diku.dk&gt;, 2006</p>\r
914<p>This program is free software; you can redistribute it and/or modify\r
915it under the terms of the GNU General Public License as published by\r
916the Free Software Foundation; either version 2 of the License, or\r
917(at your option) any later version.</p>\r
918</div>\r
919<h2>SEE ALSO</h2>\r
920<div class="sectionbody">\r
921<div class="verseblock">\r
922<div class="content"><a href="http://www.kernel.org/pub/software/scm/git/docs/">git(7)</a>,\r
923<a href="http://www.kernel.org/pub/software/scm/cogito/docs/">cogito(7)</a>\r
924gitk(1): git repository browser written using tcl/tk,\r
925gitview(1): git repository browser written using python/gtk.</div></div>\r
926</div>\r
927<div id="footer">\r
928<div id="footer-text">\r
56235576 929Last updated 17-May-2006 12:54:05 CEST\r
2b9c2ad0
JF
930</div>\r
931</div>\r
932</body>\r
933</html>\r