"Fossies" - the Fresh Open Source Software Archive

Member "git-log.html" (15 Dec 2018, 140469 Bytes) of package /linux/misc/git-htmldocs-2.20.1.tar.xz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) HTML source code syntax highlighting (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 <?xml version="1.0" encoding="UTF-8"?>
    2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
    3     "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
    4 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
    5 <head>
    6 <meta http-equiv="Content-Type" content="application/xhtml+xml; charset=UTF-8" />
    7 <meta name="generator" content="AsciiDoc 8.6.10" />
    8 <title>git-log(1)</title>
    9 <style type="text/css">
   10 /* Shared CSS for AsciiDoc xhtml11 and html5 backends */
   11 
   12 /* Default font. */
   13 body {
   14   font-family: Georgia,serif;
   15 }
   16 
   17 /* Title font. */
   18 h1, h2, h3, h4, h5, h6,
   19 div.title, caption.title,
   20 thead, p.table.header,
   21 #toctitle,
   22 #author, #revnumber, #revdate, #revremark,
   23 #footer {
   24   font-family: Arial,Helvetica,sans-serif;
   25 }
   26 
   27 body {
   28   margin: 1em 5% 1em 5%;
   29 }
   30 
   31 a {
   32   color: blue;
   33   text-decoration: underline;
   34 }
   35 a:visited {
   36   color: fuchsia;
   37 }
   38 
   39 em {
   40   font-style: italic;
   41   color: navy;
   42 }
   43 
   44 strong {
   45   font-weight: bold;
   46   color: #083194;
   47 }
   48 
   49 h1, h2, h3, h4, h5, h6 {
   50   color: #527bbd;
   51   margin-top: 1.2em;
   52   margin-bottom: 0.5em;
   53   line-height: 1.3;
   54 }
   55 
   56 h1, h2, h3 {
   57   border-bottom: 2px solid silver;
   58 }
   59 h2 {
   60   padding-top: 0.5em;
   61 }
   62 h3 {
   63   float: left;
   64 }
   65 h3 + * {
   66   clear: left;
   67 }
   68 h5 {
   69   font-size: 1.0em;
   70 }
   71 
   72 div.sectionbody {
   73   margin-left: 0;
   74 }
   75 
   76 hr {
   77   border: 1px solid silver;
   78 }
   79 
   80 p {
   81   margin-top: 0.5em;
   82   margin-bottom: 0.5em;
   83 }
   84 
   85 ul, ol, li > p {
   86   margin-top: 0;
   87 }
   88 ul > li     { color: #aaa; }
   89 ul > li > * { color: black; }
   90 
   91 .monospaced, code, pre {
   92   font-family: "Courier New", Courier, monospace;
   93   font-size: inherit;
   94   color: navy;
   95   padding: 0;
   96   margin: 0;
   97 }
   98 pre {
   99   white-space: pre-wrap;
  100 }
  101 
  102 #author {
  103   color: #527bbd;
  104   font-weight: bold;
  105   font-size: 1.1em;
  106 }
  107 #email {
  108 }
  109 #revnumber, #revdate, #revremark {
  110 }
  111 
  112 #footer {
  113   font-size: small;
  114   border-top: 2px solid silver;
  115   padding-top: 0.5em;
  116   margin-top: 4.0em;
  117 }
  118 #footer-text {
  119   float: left;
  120   padding-bottom: 0.5em;
  121 }
  122 #footer-badges {
  123   float: right;
  124   padding-bottom: 0.5em;
  125 }
  126 
  127 #preamble {
  128   margin-top: 1.5em;
  129   margin-bottom: 1.5em;
  130 }
  131 div.imageblock, div.exampleblock, div.verseblock,
  132 div.quoteblock, div.literalblock, div.listingblock, div.sidebarblock,
  133 div.admonitionblock {
  134   margin-top: 1.0em;
  135   margin-bottom: 1.5em;
  136 }
  137 div.admonitionblock {
  138   margin-top: 2.0em;
  139   margin-bottom: 2.0em;
  140   margin-right: 10%;
  141   color: #606060;
  142 }
  143 
  144 div.content { /* Block element content. */
  145   padding: 0;
  146 }
  147 
  148 /* Block element titles. */
  149 div.title, caption.title {
  150   color: #527bbd;
  151   font-weight: bold;
  152   text-align: left;
  153   margin-top: 1.0em;
  154   margin-bottom: 0.5em;
  155 }
  156 div.title + * {
  157   margin-top: 0;
  158 }
  159 
  160 td div.title:first-child {
  161   margin-top: 0.0em;
  162 }
  163 div.content div.title:first-child {
  164   margin-top: 0.0em;
  165 }
  166 div.content + div.title {
  167   margin-top: 0.0em;
  168 }
  169 
  170 div.sidebarblock > div.content {
  171   background: #ffffee;
  172   border: 1px solid #dddddd;
  173   border-left: 4px solid #f0f0f0;
  174   padding: 0.5em;
  175 }
  176 
  177 div.listingblock > div.content {
  178   border: 1px solid #dddddd;
  179   border-left: 5px solid #f0f0f0;
  180   background: #f8f8f8;
  181   padding: 0.5em;
  182 }
  183 
  184 div.quoteblock, div.verseblock {
  185   padding-left: 1.0em;
  186   margin-left: 1.0em;
  187   margin-right: 10%;
  188   border-left: 5px solid #f0f0f0;
  189   color: #888;
  190 }
  191 
  192 div.quoteblock > div.attribution {
  193   padding-top: 0.5em;
  194   text-align: right;
  195 }
  196 
  197 div.verseblock > pre.content {
  198   font-family: inherit;
  199   font-size: inherit;
  200 }
  201 div.verseblock > div.attribution {
  202   padding-top: 0.75em;
  203   text-align: left;
  204 }
  205 /* DEPRECATED: Pre version 8.2.7 verse style literal block. */
  206 div.verseblock + div.attribution {
  207   text-align: left;
  208 }
  209 
  210 div.admonitionblock .icon {
  211   vertical-align: top;
  212   font-size: 1.1em;
  213   font-weight: bold;
  214   text-decoration: underline;
  215   color: #527bbd;
  216   padding-right: 0.5em;
  217 }
  218 div.admonitionblock td.content {
  219   padding-left: 0.5em;
  220   border-left: 3px solid #dddddd;
  221 }
  222 
  223 div.exampleblock > div.content {
  224   border-left: 3px solid #dddddd;
  225   padding-left: 0.5em;
  226 }
  227 
  228 div.imageblock div.content { padding-left: 0; }
  229 span.image img { border-style: none; vertical-align: text-bottom; }
  230 a.image:visited { color: white; }
  231 
  232 dl {
  233   margin-top: 0.8em;
  234   margin-bottom: 0.8em;
  235 }
  236 dt {
  237   margin-top: 0.5em;
  238   margin-bottom: 0;
  239   font-style: normal;
  240   color: navy;
  241 }
  242 dd > *:first-child {
  243   margin-top: 0.1em;
  244 }
  245 
  246 ul, ol {
  247     list-style-position: outside;
  248 }
  249 ol.arabic {
  250   list-style-type: decimal;
  251 }
  252 ol.loweralpha {
  253   list-style-type: lower-alpha;
  254 }
  255 ol.upperalpha {
  256   list-style-type: upper-alpha;
  257 }
  258 ol.lowerroman {
  259   list-style-type: lower-roman;
  260 }
  261 ol.upperroman {
  262   list-style-type: upper-roman;
  263 }
  264 
  265 div.compact ul, div.compact ol,
  266 div.compact p, div.compact p,
  267 div.compact div, div.compact div {
  268   margin-top: 0.1em;
  269   margin-bottom: 0.1em;
  270 }
  271 
  272 tfoot {
  273   font-weight: bold;
  274 }
  275 td > div.verse {
  276   white-space: pre;
  277 }
  278 
  279 div.hdlist {
  280   margin-top: 0.8em;
  281   margin-bottom: 0.8em;
  282 }
  283 div.hdlist tr {
  284   padding-bottom: 15px;
  285 }
  286 dt.hdlist1.strong, td.hdlist1.strong {
  287   font-weight: bold;
  288 }
  289 td.hdlist1 {
  290   vertical-align: top;
  291   font-style: normal;
  292   padding-right: 0.8em;
  293   color: navy;
  294 }
  295 td.hdlist2 {
  296   vertical-align: top;
  297 }
  298 div.hdlist.compact tr {
  299   margin: 0;
  300   padding-bottom: 0;
  301 }
  302 
  303 .comment {
  304   background: yellow;
  305 }
  306 
  307 .footnote, .footnoteref {
  308   font-size: 0.8em;
  309 }
  310 
  311 span.footnote, span.footnoteref {
  312   vertical-align: super;
  313 }
  314 
  315 #footnotes {
  316   margin: 20px 0 20px 0;
  317   padding: 7px 0 0 0;
  318 }
  319 
  320 #footnotes div.footnote {
  321   margin: 0 0 5px 0;
  322 }
  323 
  324 #footnotes hr {
  325   border: none;
  326   border-top: 1px solid silver;
  327   height: 1px;
  328   text-align: left;
  329   margin-left: 0;
  330   width: 20%;
  331   min-width: 100px;
  332 }
  333 
  334 div.colist td {
  335   padding-right: 0.5em;
  336   padding-bottom: 0.3em;
  337   vertical-align: top;
  338 }
  339 div.colist td img {
  340   margin-top: 0.3em;
  341 }
  342 
  343 @media print {
  344   #footer-badges { display: none; }
  345 }
  346 
  347 #toc {
  348   margin-bottom: 2.5em;
  349 }
  350 
  351 #toctitle {
  352   color: #527bbd;
  353   font-size: 1.1em;
  354   font-weight: bold;
  355   margin-top: 1.0em;
  356   margin-bottom: 0.1em;
  357 }
  358 
  359 div.toclevel0, div.toclevel1, div.toclevel2, div.toclevel3, div.toclevel4 {
  360   margin-top: 0;
  361   margin-bottom: 0;
  362 }
  363 div.toclevel2 {
  364   margin-left: 2em;
  365   font-size: 0.9em;
  366 }
  367 div.toclevel3 {
  368   margin-left: 4em;
  369   font-size: 0.9em;
  370 }
  371 div.toclevel4 {
  372   margin-left: 6em;
  373   font-size: 0.9em;
  374 }
  375 
  376 span.aqua { color: aqua; }
  377 span.black { color: black; }
  378 span.blue { color: blue; }
  379 span.fuchsia { color: fuchsia; }
  380 span.gray { color: gray; }
  381 span.green { color: green; }
  382 span.lime { color: lime; }
  383 span.maroon { color: maroon; }
  384 span.navy { color: navy; }
  385 span.olive { color: olive; }
  386 span.purple { color: purple; }
  387 span.red { color: red; }
  388 span.silver { color: silver; }
  389 span.teal { color: teal; }
  390 span.white { color: white; }
  391 span.yellow { color: yellow; }
  392 
  393 span.aqua-background { background: aqua; }
  394 span.black-background { background: black; }
  395 span.blue-background { background: blue; }
  396 span.fuchsia-background { background: fuchsia; }
  397 span.gray-background { background: gray; }
  398 span.green-background { background: green; }
  399 span.lime-background { background: lime; }
  400 span.maroon-background { background: maroon; }
  401 span.navy-background { background: navy; }
  402 span.olive-background { background: olive; }
  403 span.purple-background { background: purple; }
  404 span.red-background { background: red; }
  405 span.silver-background { background: silver; }
  406 span.teal-background { background: teal; }
  407 span.white-background { background: white; }
  408 span.yellow-background { background: yellow; }
  409 
  410 span.big { font-size: 2em; }
  411 span.small { font-size: 0.6em; }
  412 
  413 span.underline { text-decoration: underline; }
  414 span.overline { text-decoration: overline; }
  415 span.line-through { text-decoration: line-through; }
  416 
  417 div.unbreakable { page-break-inside: avoid; }
  418 
  419 
  420 /*
  421  * xhtml11 specific
  422  *
  423  * */
  424 
  425 div.tableblock {
  426   margin-top: 1.0em;
  427   margin-bottom: 1.5em;
  428 }
  429 div.tableblock > table {
  430   border: 3px solid #527bbd;
  431 }
  432 thead, p.table.header {
  433   font-weight: bold;
  434   color: #527bbd;
  435 }
  436 p.table {
  437   margin-top: 0;
  438 }
  439 /* Because the table frame attribute is overriden by CSS in most browsers. */
  440 div.tableblock > table[frame="void"] {
  441   border-style: none;
  442 }
  443 div.tableblock > table[frame="hsides"] {
  444   border-left-style: none;
  445   border-right-style: none;
  446 }
  447 div.tableblock > table[frame="vsides"] {
  448   border-top-style: none;
  449   border-bottom-style: none;
  450 }
  451 
  452 
  453 /*
  454  * html5 specific
  455  *
  456  * */
  457 
  458 table.tableblock {
  459   margin-top: 1.0em;
  460   margin-bottom: 1.5em;
  461 }
  462 thead, p.tableblock.header {
  463   font-weight: bold;
  464   color: #527bbd;
  465 }
  466 p.tableblock {
  467   margin-top: 0;
  468 }
  469 table.tableblock {
  470   border-width: 3px;
  471   border-spacing: 0px;
  472   border-style: solid;
  473   border-color: #527bbd;
  474   border-collapse: collapse;
  475 }
  476 th.tableblock, td.tableblock {
  477   border-width: 1px;
  478   padding: 4px;
  479   border-style: solid;
  480   border-color: #527bbd;
  481 }
  482 
  483 table.tableblock.frame-topbot {
  484   border-left-style: hidden;
  485   border-right-style: hidden;
  486 }
  487 table.tableblock.frame-sides {
  488   border-top-style: hidden;
  489   border-bottom-style: hidden;
  490 }
  491 table.tableblock.frame-none {
  492   border-style: hidden;
  493 }
  494 
  495 th.tableblock.halign-left, td.tableblock.halign-left {
  496   text-align: left;
  497 }
  498 th.tableblock.halign-center, td.tableblock.halign-center {
  499   text-align: center;
  500 }
  501 th.tableblock.halign-right, td.tableblock.halign-right {
  502   text-align: right;
  503 }
  504 
  505 th.tableblock.valign-top, td.tableblock.valign-top {
  506   vertical-align: top;
  507 }
  508 th.tableblock.valign-middle, td.tableblock.valign-middle {
  509   vertical-align: middle;
  510 }
  511 th.tableblock.valign-bottom, td.tableblock.valign-bottom {
  512   vertical-align: bottom;
  513 }
  514 
  515 
  516 /*
  517  * manpage specific
  518  *
  519  * */
  520 
  521 body.manpage h1 {
  522   padding-top: 0.5em;
  523   padding-bottom: 0.5em;
  524   border-top: 2px solid silver;
  525   border-bottom: 2px solid silver;
  526 }
  527 body.manpage h2 {
  528   border-style: none;
  529 }
  530 body.manpage div.sectionbody {
  531   margin-left: 3em;
  532 }
  533 
  534 @media print {
  535   body.manpage div#toc { display: none; }
  536 }
  537 
  538 
  539 </style>
  540 <script type="text/javascript">
  541 /*<![CDATA[*/
  542 var asciidoc = {  // Namespace.
  543 
  544 /////////////////////////////////////////////////////////////////////
  545 // Table Of Contents generator
  546 /////////////////////////////////////////////////////////////////////
  547 
  548 /* Author: Mihai Bazon, September 2002
  549  * http://students.infoiasi.ro/~mishoo
  550  *
  551  * Table Of Content generator
  552  * Version: 0.4
  553  *
  554  * Feel free to use this script under the terms of the GNU General Public
  555  * License, as long as you do not remove or alter this notice.
  556  */
  557 
  558  /* modified by Troy D. Hanson, September 2006. License: GPL */
  559  /* modified by Stuart Rackham, 2006, 2009. License: GPL */
  560 
  561 // toclevels = 1..4.
  562 toc: function (toclevels) {
  563 
  564   function getText(el) {
  565     var text = "";
  566     for (var i = el.firstChild; i != null; i = i.nextSibling) {
  567       if (i.nodeType == 3 /* Node.TEXT_NODE */) // IE doesn't speak constants.
  568         text += i.data;
  569       else if (i.firstChild != null)
  570         text += getText(i);
  571     }
  572     return text;
  573   }
  574 
  575   function TocEntry(el, text, toclevel) {
  576     this.element = el;
  577     this.text = text;
  578     this.toclevel = toclevel;
  579   }
  580 
  581   function tocEntries(el, toclevels) {
  582     var result = new Array;
  583     var re = new RegExp('[hH]([1-'+(toclevels+1)+'])');
  584     // Function that scans the DOM tree for header elements (the DOM2
  585     // nodeIterator API would be a better technique but not supported by all
  586     // browsers).
  587     var iterate = function (el) {
  588       for (var i = el.firstChild; i != null; i = i.nextSibling) {
  589         if (i.nodeType == 1 /* Node.ELEMENT_NODE */) {
  590           var mo = re.exec(i.tagName);
  591           if (mo && (i.getAttribute("class") || i.getAttribute("className")) != "float") {
  592             result[result.length] = new TocEntry(i, getText(i), mo[1]-1);
  593           }
  594           iterate(i);
  595         }
  596       }
  597     }
  598     iterate(el);
  599     return result;
  600   }
  601 
  602   var toc = document.getElementById("toc");
  603   if (!toc) {
  604     return;
  605   }
  606 
  607   // Delete existing TOC entries in case we're reloading the TOC.
  608   var tocEntriesToRemove = [];
  609   var i;
  610   for (i = 0; i < toc.childNodes.length; i++) {
  611     var entry = toc.childNodes[i];
  612     if (entry.nodeName.toLowerCase() == 'div'
  613      && entry.getAttribute("class")
  614      && entry.getAttribute("class").match(/^toclevel/))
  615       tocEntriesToRemove.push(entry);
  616   }
  617   for (i = 0; i < tocEntriesToRemove.length; i++) {
  618     toc.removeChild(tocEntriesToRemove[i]);
  619   }
  620 
  621   // Rebuild TOC entries.
  622   var entries = tocEntries(document.getElementById("content"), toclevels);
  623   for (var i = 0; i < entries.length; ++i) {
  624     var entry = entries[i];
  625     if (entry.element.id == "")
  626       entry.element.id = "_toc_" + i;
  627     var a = document.createElement("a");
  628     a.href = "#" + entry.element.id;
  629     a.appendChild(document.createTextNode(entry.text));
  630     var div = document.createElement("div");
  631     div.appendChild(a);
  632     div.className = "toclevel" + entry.toclevel;
  633     toc.appendChild(div);
  634   }
  635   if (entries.length == 0)
  636     toc.parentNode.removeChild(toc);
  637 },
  638 
  639 
  640 /////////////////////////////////////////////////////////////////////
  641 // Footnotes generator
  642 /////////////////////////////////////////////////////////////////////
  643 
  644 /* Based on footnote generation code from:
  645  * http://www.brandspankingnew.net/archive/2005/07/format_footnote.html
  646  */
  647 
  648 footnotes: function () {
  649   // Delete existing footnote entries in case we're reloading the footnodes.
  650   var i;
  651   var noteholder = document.getElementById("footnotes");
  652   if (!noteholder) {
  653     return;
  654   }
  655   var entriesToRemove = [];
  656   for (i = 0; i < noteholder.childNodes.length; i++) {
  657     var entry = noteholder.childNodes[i];
  658     if (entry.nodeName.toLowerCase() == 'div' && entry.getAttribute("class") == "footnote")
  659       entriesToRemove.push(entry);
  660   }
  661   for (i = 0; i < entriesToRemove.length; i++) {
  662     noteholder.removeChild(entriesToRemove[i]);
  663   }
  664 
  665   // Rebuild footnote entries.
  666   var cont = document.getElementById("content");
  667   var spans = cont.getElementsByTagName("span");
  668   var refs = {};
  669   var n = 0;
  670   for (i=0; i<spans.length; i++) {
  671     if (spans[i].className == "footnote") {
  672       n++;
  673       var note = spans[i].getAttribute("data-note");
  674       if (!note) {
  675         // Use [\s\S] in place of . so multi-line matches work.
  676         // Because JavaScript has no s (dotall) regex flag.
  677         note = spans[i].innerHTML.match(/\s*\[([\s\S]*)]\s*/)[1];
  678         spans[i].innerHTML =
  679           "[<a id='_footnoteref_" + n + "' href='#_footnote_" + n +
  680           "' title='View footnote' class='footnote'>" + n + "</a>]";
  681         spans[i].setAttribute("data-note", note);
  682       }
  683       noteholder.innerHTML +=
  684         "<div class='footnote' id='_footnote_" + n + "'>" +
  685         "<a href='#_footnoteref_" + n + "' title='Return to text'>" +
  686         n + "</a>. " + note + "</div>";
  687       var id =spans[i].getAttribute("id");
  688       if (id != null) refs["#"+id] = n;
  689     }
  690   }
  691   if (n == 0)
  692     noteholder.parentNode.removeChild(noteholder);
  693   else {
  694     // Process footnoterefs.
  695     for (i=0; i<spans.length; i++) {
  696       if (spans[i].className == "footnoteref") {
  697         var href = spans[i].getElementsByTagName("a")[0].getAttribute("href");
  698         href = href.match(/#.*/)[0];  // Because IE return full URL.
  699         n = refs[href];
  700         spans[i].innerHTML =
  701           "[<a href='#_footnote_" + n +
  702           "' title='View footnote' class='footnote'>" + n + "</a>]";
  703       }
  704     }
  705   }
  706 },
  707 
  708 install: function(toclevels) {
  709   var timerId;
  710 
  711   function reinstall() {
  712     asciidoc.footnotes();
  713     if (toclevels) {
  714       asciidoc.toc(toclevels);
  715     }
  716   }
  717 
  718   function reinstallAndRemoveTimer() {
  719     clearInterval(timerId);
  720     reinstall();
  721   }
  722 
  723   timerId = setInterval(reinstall, 500);
  724   if (document.addEventListener)
  725     document.addEventListener("DOMContentLoaded", reinstallAndRemoveTimer, false);
  726   else
  727     window.onload = reinstallAndRemoveTimer;
  728 }
  729 
  730 }
  731 asciidoc.install();
  732 /*]]>*/
  733 </script>
  734 </head>
  735 <body class="manpage">
  736 <div id="header">
  737 <h1>
  738 git-log(1) Manual Page
  739 </h1>
  740 <h2>NAME</h2>
  741 <div class="sectionbody">
  742 <p>git-log -
  743    Show commit logs
  744 </p>
  745 </div>
  746 </div>
  747 <div id="content">
  748 <div class="sect1">
  749 <h2 id="_synopsis">SYNOPSIS</h2>
  750 <div class="sectionbody">
  751 <div class="verseblock">
  752 <pre class="content"><em>git log</em> [&lt;options&gt;] [&lt;revision range&gt;] [[--] &lt;path&gt;&#8230;]</pre>
  753 <div class="attribution">
  754 </div></div>
  755 </div>
  756 </div>
  757 <div class="sect1">
  758 <h2 id="_description">DESCRIPTION</h2>
  759 <div class="sectionbody">
  760 <div class="paragraph"><p>Shows the commit logs.</p></div>
  761 <div class="paragraph"><p>The command takes options applicable to the <code>git rev-list</code>
  762 command to control what is shown and how, and options applicable to
  763 the <code>git diff-*</code> commands to control how the changes
  764 each commit introduces are shown.</p></div>
  765 </div>
  766 </div>
  767 <div class="sect1">
  768 <h2 id="_options">OPTIONS</h2>
  769 <div class="sectionbody">
  770 <div class="dlist"><dl>
  771 <dt class="hdlist1">
  772 --follow
  773 </dt>
  774 <dd>
  775 <p>
  776         Continue listing the history of a file beyond renames
  777         (works only for a single file).
  778 </p>
  779 </dd>
  780 <dt class="hdlist1">
  781 --no-decorate
  782 </dt>
  783 <dt class="hdlist1">
  784 --decorate[=short|full|auto|no]
  785 </dt>
  786 <dd>
  787 <p>
  788         Print out the ref names of any commits that are shown. If <em>short</em> is
  789         specified, the ref name prefixes <em>refs/heads/</em>, <em>refs/tags/</em> and
  790         <em>refs/remotes/</em> will not be printed. If <em>full</em> is specified, the
  791         full ref name (including prefix) will be printed. If <em>auto</em> is
  792         specified, then if the output is going to a terminal, the ref names
  793         are shown as if <em>short</em> were given, otherwise no ref names are
  794         shown. The default option is <em>short</em>.
  795 </p>
  796 </dd>
  797 <dt class="hdlist1">
  798 --decorate-refs=&lt;pattern&gt;
  799 </dt>
  800 <dt class="hdlist1">
  801 --decorate-refs-exclude=&lt;pattern&gt;
  802 </dt>
  803 <dd>
  804 <p>
  805         If no <code>--decorate-refs</code> is given, pretend as if all refs were
  806         included.  For each candidate, do not use it for decoration if it
  807         matches any patterns given to <code>--decorate-refs-exclude</code> or if it
  808         doesn&#8217;t match any of the patterns given to <code>--decorate-refs</code>.
  809 </p>
  810 </dd>
  811 <dt class="hdlist1">
  812 --source
  813 </dt>
  814 <dd>
  815 <p>
  816         Print out the ref name given on the command line by which each
  817         commit was reached.
  818 </p>
  819 </dd>
  820 <dt class="hdlist1">
  821 --use-mailmap
  822 </dt>
  823 <dd>
  824 <p>
  825         Use mailmap file to map author and committer names and email
  826         addresses to canonical real names and email addresses. See
  827         <a href="git-shortlog.html">git-shortlog(1)</a>.
  828 </p>
  829 </dd>
  830 <dt class="hdlist1">
  831 --full-diff
  832 </dt>
  833 <dd>
  834 <p>
  835         Without this flag, <code>git log -p &lt;path&gt;...</code> shows commits that
  836         touch the specified paths, and diffs about the same specified
  837         paths.  With this, the full diff is shown for commits that touch
  838         the specified paths; this means that "&lt;path&gt;&#8230;" limits only
  839         commits, and doesn&#8217;t limit diff for those commits.
  840 </p>
  841 <div class="paragraph"><p>Note that this affects all diff-based output types, e.g. those
  842 produced by <code>--stat</code>, etc.</p></div>
  843 </dd>
  844 <dt class="hdlist1">
  845 --log-size
  846 </dt>
  847 <dd>
  848 <p>
  849         Include a line &#8220;log size &lt;number&gt;&#8221; in the output for each commit,
  850         where &lt;number&gt; is the length of that commit&#8217;s message in bytes.
  851         Intended to speed up tools that read log messages from <code>git log</code>
  852         output by allowing them to allocate space in advance.
  853 </p>
  854 </dd>
  855 <dt class="hdlist1">
  856 -L &lt;start&gt;,&lt;end&gt;:&lt;file&gt;
  857 </dt>
  858 <dt class="hdlist1">
  859 -L :&lt;funcname&gt;:&lt;file&gt;
  860 </dt>
  861 <dd>
  862 <p>
  863         Trace the evolution of the line range given by "&lt;start&gt;,&lt;end&gt;"
  864         (or the function name regex &lt;funcname&gt;) within the &lt;file&gt;.  You may
  865         not give any pathspec limiters.  This is currently limited to
  866         a walk starting from a single revision, i.e., you may only
  867         give zero or one positive revision arguments.
  868         You can specify this option more than once.
  869 </p>
  870 <div class="paragraph"><p>&lt;start&gt; and &lt;end&gt; can take one of these forms:</p></div>
  871 <div class="ulist"><ul>
  872 <li>
  873 <p>
  874 number
  875 </p>
  876 <div class="paragraph"><p>If &lt;start&gt; or &lt;end&gt; is a number, it specifies an
  877 absolute line number (lines count from 1).</p></div>
  878 </li>
  879 <li>
  880 <p>
  881 /regex/
  882 </p>
  883 <div class="paragraph"><p>This form will use the first line matching the given
  884 POSIX regex. If &lt;start&gt; is a regex, it will search from the end of
  885 the previous <code>-L</code> range, if any, otherwise from the start of file.
  886 If &lt;start&gt; is &#8220;^/regex/&#8221;, it will search from the start of file.
  887 If &lt;end&gt; is a regex, it will search
  888 starting at the line given by &lt;start&gt;.</p></div>
  889 </li>
  890 <li>
  891 <p>
  892 +offset or -offset
  893 </p>
  894 <div class="paragraph"><p>This is only valid for &lt;end&gt; and will specify a number
  895 of lines before or after the line given by &lt;start&gt;.</p></div>
  896 </li>
  897 </ul></div>
  898 <div class="paragraph"><p>If &#8220;:&lt;funcname&gt;&#8221; is given in place of &lt;start&gt; and &lt;end&gt;, it is a
  899 regular expression that denotes the range from the first funcname line
  900 that matches &lt;funcname&gt;, up to the next funcname line. &#8220;:&lt;funcname&gt;&#8221;
  901 searches from the end of the previous <code>-L</code> range, if any, otherwise
  902 from the start of file. &#8220;^:&lt;funcname&gt;&#8221; searches from the start of
  903 file.</p></div>
  904 </dd>
  905 <dt class="hdlist1">
  906 &lt;revision range&gt;
  907 </dt>
  908 <dd>
  909 <p>
  910         Show only commits in the specified revision range.  When no
  911         &lt;revision range&gt; is specified, it defaults to <code>HEAD</code> (i.e. the
  912         whole history leading to the current commit).  <code>origin..HEAD</code>
  913         specifies all the commits reachable from the current commit
  914         (i.e. <code>HEAD</code>), but not from <code>origin</code>. For a complete list of
  915         ways to spell &lt;revision range&gt;, see the <em>Specifying Ranges</em>
  916         section of <a href="gitrevisions.html">gitrevisions(7)</a>.
  917 </p>
  918 </dd>
  919 <dt class="hdlist1">
  920 [--] &lt;path&gt;&#8230;
  921 </dt>
  922 <dd>
  923 <p>
  924         Show only commits that are enough to explain how the files
  925         that match the specified paths came to be.  See <em>History
  926         Simplification</em> below for details and other simplification
  927         modes.
  928 </p>
  929 <div class="paragraph"><p>Paths may need to be prefixed with <code>--</code> to separate them from
  930 options or the revision range, when confusion arises.</p></div>
  931 </dd>
  932 </dl></div>
  933 <div class="sect2">
  934 <h3 id="_commit_limiting">Commit Limiting</h3>
  935 <div class="paragraph"><p>Besides specifying a range of commits that should be listed using the
  936 special notations explained in the description, additional commit
  937 limiting may be applied.</p></div>
  938 <div class="paragraph"><p>Using more options generally further limits the output (e.g.
  939 <code>--since=&lt;date1&gt;</code> limits to commits newer than <code>&lt;date1&gt;</code>, and using it
  940 with <code>--grep=&lt;pattern&gt;</code> further limits to commits whose log message
  941 has a line that matches <code>&lt;pattern&gt;</code>), unless otherwise noted.</p></div>
  942 <div class="paragraph"><p>Note that these are applied before commit
  943 ordering and formatting options, such as <code>--reverse</code>.</p></div>
  944 <div class="openblock">
  945 <div class="content">
  946 <div class="dlist"><dl>
  947 <dt class="hdlist1">
  948 -&lt;number&gt;
  949 </dt>
  950 <dt class="hdlist1">
  951 -n &lt;number&gt;
  952 </dt>
  953 <dt class="hdlist1">
  954 --max-count=&lt;number&gt;
  955 </dt>
  956 <dd>
  957 <p>
  958         Limit the number of commits to output.
  959 </p>
  960 </dd>
  961 <dt class="hdlist1">
  962 --skip=&lt;number&gt;
  963 </dt>
  964 <dd>
  965 <p>
  966         Skip <em>number</em> commits before starting to show the commit output.
  967 </p>
  968 </dd>
  969 <dt class="hdlist1">
  970 --since=&lt;date&gt;
  971 </dt>
  972 <dt class="hdlist1">
  973 --after=&lt;date&gt;
  974 </dt>
  975 <dd>
  976 <p>
  977         Show commits more recent than a specific date.
  978 </p>
  979 </dd>
  980 <dt class="hdlist1">
  981 --until=&lt;date&gt;
  982 </dt>
  983 <dt class="hdlist1">
  984 --before=&lt;date&gt;
  985 </dt>
  986 <dd>
  987 <p>
  988         Show commits older than a specific date.
  989 </p>
  990 </dd>
  991 <dt class="hdlist1">
  992 --author=&lt;pattern&gt;
  993 </dt>
  994 <dt class="hdlist1">
  995 --committer=&lt;pattern&gt;
  996 </dt>
  997 <dd>
  998 <p>
  999         Limit the commits output to ones with author/committer
 1000         header lines that match the specified pattern (regular
 1001         expression).  With more than one <code>--author=&lt;pattern&gt;</code>,
 1002         commits whose author matches any of the given patterns are
 1003         chosen (similarly for multiple <code>--committer=&lt;pattern&gt;</code>).
 1004 </p>
 1005 </dd>
 1006 <dt class="hdlist1">
 1007 --grep-reflog=&lt;pattern&gt;
 1008 </dt>
 1009 <dd>
 1010 <p>
 1011         Limit the commits output to ones with reflog entries that
 1012         match the specified pattern (regular expression). With
 1013         more than one <code>--grep-reflog</code>, commits whose reflog message
 1014         matches any of the given patterns are chosen.  It is an
 1015         error to use this option unless <code>--walk-reflogs</code> is in use.
 1016 </p>
 1017 </dd>
 1018 <dt class="hdlist1">
 1019 --grep=&lt;pattern&gt;
 1020 </dt>
 1021 <dd>
 1022 <p>
 1023         Limit the commits output to ones with log message that
 1024         matches the specified pattern (regular expression).  With
 1025         more than one <code>--grep=&lt;pattern&gt;</code>, commits whose message
 1026         matches any of the given patterns are chosen (but see
 1027         <code>--all-match</code>).
 1028 </p>
 1029 <div class="paragraph"><p>When <code>--show-notes</code> is in effect, the message from the notes is
 1030 matched as if it were part of the log message.</p></div>
 1031 </dd>
 1032 <dt class="hdlist1">
 1033 --all-match
 1034 </dt>
 1035 <dd>
 1036 <p>
 1037         Limit the commits output to ones that match all given <code>--grep</code>,
 1038         instead of ones that match at least one.
 1039 </p>
 1040 </dd>
 1041 <dt class="hdlist1">
 1042 --invert-grep
 1043 </dt>
 1044 <dd>
 1045 <p>
 1046         Limit the commits output to ones with log message that do not
 1047         match the pattern specified with <code>--grep=&lt;pattern&gt;</code>.
 1048 </p>
 1049 </dd>
 1050 <dt class="hdlist1">
 1051 -i
 1052 </dt>
 1053 <dt class="hdlist1">
 1054 --regexp-ignore-case
 1055 </dt>
 1056 <dd>
 1057 <p>
 1058         Match the regular expression limiting patterns without regard to letter
 1059         case.
 1060 </p>
 1061 </dd>
 1062 <dt class="hdlist1">
 1063 --basic-regexp
 1064 </dt>
 1065 <dd>
 1066 <p>
 1067         Consider the limiting patterns to be basic regular expressions;
 1068         this is the default.
 1069 </p>
 1070 </dd>
 1071 <dt class="hdlist1">
 1072 -E
 1073 </dt>
 1074 <dt class="hdlist1">
 1075 --extended-regexp
 1076 </dt>
 1077 <dd>
 1078 <p>
 1079         Consider the limiting patterns to be extended regular expressions
 1080         instead of the default basic regular expressions.
 1081 </p>
 1082 </dd>
 1083 <dt class="hdlist1">
 1084 -F
 1085 </dt>
 1086 <dt class="hdlist1">
 1087 --fixed-strings
 1088 </dt>
 1089 <dd>
 1090 <p>
 1091         Consider the limiting patterns to be fixed strings (don&#8217;t interpret
 1092         pattern as a regular expression).
 1093 </p>
 1094 </dd>
 1095 <dt class="hdlist1">
 1096 -P
 1097 </dt>
 1098 <dt class="hdlist1">
 1099 --perl-regexp
 1100 </dt>
 1101 <dd>
 1102 <p>
 1103         Consider the limiting patterns to be Perl-compatible regular
 1104         expressions.
 1105 </p>
 1106 <div class="paragraph"><p>Support for these types of regular expressions is an optional
 1107 compile-time dependency. If Git wasn&#8217;t compiled with support for them
 1108 providing this option will cause it to die.</p></div>
 1109 </dd>
 1110 <dt class="hdlist1">
 1111 --remove-empty
 1112 </dt>
 1113 <dd>
 1114 <p>
 1115         Stop when a given path disappears from the tree.
 1116 </p>
 1117 </dd>
 1118 <dt class="hdlist1">
 1119 --merges
 1120 </dt>
 1121 <dd>
 1122 <p>
 1123         Print only merge commits. This is exactly the same as <code>--min-parents=2</code>.
 1124 </p>
 1125 </dd>
 1126 <dt class="hdlist1">
 1127 --no-merges
 1128 </dt>
 1129 <dd>
 1130 <p>
 1131         Do not print commits with more than one parent. This is
 1132         exactly the same as <code>--max-parents=1</code>.
 1133 </p>
 1134 </dd>
 1135 <dt class="hdlist1">
 1136 --min-parents=&lt;number&gt;
 1137 </dt>
 1138 <dt class="hdlist1">
 1139 --max-parents=&lt;number&gt;
 1140 </dt>
 1141 <dt class="hdlist1">
 1142 --no-min-parents
 1143 </dt>
 1144 <dt class="hdlist1">
 1145 --no-max-parents
 1146 </dt>
 1147 <dd>
 1148 <p>
 1149         Show only commits which have at least (or at most) that many parent
 1150         commits. In particular, <code>--max-parents=1</code> is the same as <code>--no-merges</code>,
 1151         <code>--min-parents=2</code> is the same as <code>--merges</code>.  <code>--max-parents=0</code>
 1152         gives all root commits and <code>--min-parents=3</code> all octopus merges.
 1153 </p>
 1154 <div class="paragraph"><p><code>--no-min-parents</code> and <code>--no-max-parents</code> reset these limits (to no limit)
 1155 again.  Equivalent forms are <code>--min-parents=0</code> (any commit has 0 or more
 1156 parents) and <code>--max-parents=-1</code> (negative numbers denote no upper limit).</p></div>
 1157 </dd>
 1158 <dt class="hdlist1">
 1159 --first-parent
 1160 </dt>
 1161 <dd>
 1162 <p>
 1163         Follow only the first parent commit upon seeing a merge
 1164         commit.  This option can give a better overview when
 1165         viewing the evolution of a particular topic branch,
 1166         because merges into a topic branch tend to be only about
 1167         adjusting to updated upstream from time to time, and
 1168         this option allows you to ignore the individual commits
 1169         brought in to your history by such a merge. Cannot be
 1170         combined with --bisect.
 1171 </p>
 1172 </dd>
 1173 <dt class="hdlist1">
 1174 --not
 1175 </dt>
 1176 <dd>
 1177 <p>
 1178         Reverses the meaning of the <em>&#94;</em> prefix (or lack thereof)
 1179         for all following revision specifiers, up to the next <code>--not</code>.
 1180 </p>
 1181 </dd>
 1182 <dt class="hdlist1">
 1183 --all
 1184 </dt>
 1185 <dd>
 1186 <p>
 1187         Pretend as if all the refs in <code>refs/</code>, along with <code>HEAD</code>, are
 1188         listed on the command line as <em>&lt;commit&gt;</em>.
 1189 </p>
 1190 </dd>
 1191 <dt class="hdlist1">
 1192 --branches[=&lt;pattern&gt;]
 1193 </dt>
 1194 <dd>
 1195 <p>
 1196         Pretend as if all the refs in <code>refs/heads</code> are listed
 1197         on the command line as <em>&lt;commit&gt;</em>. If <em>&lt;pattern&gt;</em> is given, limit
 1198         branches to ones matching given shell glob. If pattern lacks <em>?</em>,
 1199         <em>&#42;</em>, or <em>[</em>, <em>/&#42;</em> at the end is implied.
 1200 </p>
 1201 </dd>
 1202 <dt class="hdlist1">
 1203 --tags[=&lt;pattern&gt;]
 1204 </dt>
 1205 <dd>
 1206 <p>
 1207         Pretend as if all the refs in <code>refs/tags</code> are listed
 1208         on the command line as <em>&lt;commit&gt;</em>. If <em>&lt;pattern&gt;</em> is given, limit
 1209         tags to ones matching given shell glob. If pattern lacks <em>?</em>, <em>&#42;</em>,
 1210         or <em>[</em>, <em>/&#42;</em> at the end is implied.
 1211 </p>
 1212 </dd>
 1213 <dt class="hdlist1">
 1214 --remotes[=&lt;pattern&gt;]
 1215 </dt>
 1216 <dd>
 1217 <p>
 1218         Pretend as if all the refs in <code>refs/remotes</code> are listed
 1219         on the command line as <em>&lt;commit&gt;</em>. If <em>&lt;pattern&gt;</em> is given, limit
 1220         remote-tracking branches to ones matching given shell glob.
 1221         If pattern lacks <em>?</em>, <em>&#42;</em>, or <em>[</em>, <em>/&#42;</em> at the end is implied.
 1222 </p>
 1223 </dd>
 1224 <dt class="hdlist1">
 1225 --glob=&lt;glob-pattern&gt;
 1226 </dt>
 1227 <dd>
 1228 <p>
 1229         Pretend as if all the refs matching shell glob <em>&lt;glob-pattern&gt;</em>
 1230         are listed on the command line as <em>&lt;commit&gt;</em>. Leading <em>refs/</em>,
 1231         is automatically prepended if missing. If pattern lacks <em>?</em>, <em>&#42;</em>,
 1232         or <em>[</em>, <em>/&#42;</em> at the end is implied.
 1233 </p>
 1234 </dd>
 1235 <dt class="hdlist1">
 1236 --exclude=&lt;glob-pattern&gt;
 1237 </dt>
 1238 <dd>
 1239 <p>
 1240         Do not include refs matching <em>&lt;glob-pattern&gt;</em> that the next <code>--all</code>,
 1241         <code>--branches</code>, <code>--tags</code>, <code>--remotes</code>, or <code>--glob</code> would otherwise
 1242         consider. Repetitions of this option accumulate exclusion patterns
 1243         up to the next <code>--all</code>, <code>--branches</code>, <code>--tags</code>, <code>--remotes</code>, or
 1244         <code>--glob</code> option (other options or arguments do not clear
 1245         accumulated patterns).
 1246 </p>
 1247 <div class="paragraph"><p>The patterns given should not begin with <code>refs/heads</code>, <code>refs/tags</code>, or
 1248 <code>refs/remotes</code> when applied to <code>--branches</code>, <code>--tags</code>, or <code>--remotes</code>,
 1249 respectively, and they must begin with <code>refs/</code> when applied to <code>--glob</code>
 1250 or <code>--all</code>. If a trailing <em>/&#42;</em> is intended, it must be given
 1251 explicitly.</p></div>
 1252 </dd>
 1253 <dt class="hdlist1">
 1254 --reflog
 1255 </dt>
 1256 <dd>
 1257 <p>
 1258         Pretend as if all objects mentioned by reflogs are listed on the
 1259         command line as <code>&lt;commit&gt;</code>.
 1260 </p>
 1261 </dd>
 1262 <dt class="hdlist1">
 1263 --single-worktree
 1264 </dt>
 1265 <dd>
 1266 <p>
 1267         By default, all working trees will be examined by the
 1268         following options when there are more than one (see
 1269         <a href="git-worktree.html">git-worktree(1)</a>): <code>--all</code>, <code>--reflog</code> and
 1270         <code>--indexed-objects</code>.
 1271         This option forces them to examine the current working tree
 1272         only.
 1273 </p>
 1274 </dd>
 1275 <dt class="hdlist1">
 1276 --ignore-missing
 1277 </dt>
 1278 <dd>
 1279 <p>
 1280         Upon seeing an invalid object name in the input, pretend as if
 1281         the bad input was not given.
 1282 </p>
 1283 </dd>
 1284 <dt class="hdlist1">
 1285 --bisect
 1286 </dt>
 1287 <dd>
 1288 <p>
 1289         Pretend as if the bad bisection ref <code>refs/bisect/bad</code>
 1290         was listed and as if it was followed by <code>--not</code> and the good
 1291         bisection refs <code>refs/bisect/good-*</code> on the command
 1292         line. Cannot be combined with --first-parent.
 1293 </p>
 1294 </dd>
 1295 <dt class="hdlist1">
 1296 --stdin
 1297 </dt>
 1298 <dd>
 1299 <p>
 1300         In addition to the <em>&lt;commit&gt;</em> listed on the command
 1301         line, read them from the standard input. If a <code>--</code> separator is
 1302         seen, stop reading commits and start reading paths to limit the
 1303         result.
 1304 </p>
 1305 </dd>
 1306 <dt class="hdlist1">
 1307 --cherry-mark
 1308 </dt>
 1309 <dd>
 1310 <p>
 1311         Like <code>--cherry-pick</code> (see below) but mark equivalent commits
 1312         with <code>=</code> rather than omitting them, and inequivalent ones with <code>+</code>.
 1313 </p>
 1314 </dd>
 1315 <dt class="hdlist1">
 1316 --cherry-pick
 1317 </dt>
 1318 <dd>
 1319 <p>
 1320         Omit any commit that introduces the same change as
 1321         another commit on the &#8220;other side&#8221; when the set of
 1322         commits are limited with symmetric difference.
 1323 </p>
 1324 <div class="paragraph"><p>For example, if you have two branches, <code>A</code> and <code>B</code>, a usual way
 1325 to list all commits on only one side of them is with
 1326 <code>--left-right</code> (see the example below in the description of
 1327 the <code>--left-right</code> option). However, it shows the commits that were
 1328 cherry-picked from the other branch (for example, &#8220;3rd on b&#8221; may be
 1329 cherry-picked from branch A). With this option, such pairs of commits are
 1330 excluded from the output.</p></div>
 1331 </dd>
 1332 <dt class="hdlist1">
 1333 --left-only
 1334 </dt>
 1335 <dt class="hdlist1">
 1336 --right-only
 1337 </dt>
 1338 <dd>
 1339 <p>
 1340         List only commits on the respective side of a symmetric difference,
 1341         i.e. only those which would be marked <code>&lt;</code> resp. <code>&gt;</code> by
 1342         <code>--left-right</code>.
 1343 </p>
 1344 <div class="paragraph"><p>For example, <code>--cherry-pick --right-only A...B</code> omits those
 1345 commits from <code>B</code> which are in <code>A</code> or are patch-equivalent to a commit in
 1346 <code>A</code>. In other words, this lists the <code>+</code> commits from <code>git cherry A B</code>.
 1347 More precisely, <code>--cherry-pick --right-only --no-merges</code> gives the exact
 1348 list.</p></div>
 1349 </dd>
 1350 <dt class="hdlist1">
 1351 --cherry
 1352 </dt>
 1353 <dd>
 1354 <p>
 1355         A synonym for <code>--right-only --cherry-mark --no-merges</code>; useful to
 1356         limit the output to the commits on our side and mark those that
 1357         have been applied to the other side of a forked history with
 1358         <code>git log --cherry upstream...mybranch</code>, similar to
 1359         <code>git cherry upstream mybranch</code>.
 1360 </p>
 1361 </dd>
 1362 <dt class="hdlist1">
 1363 -g
 1364 </dt>
 1365 <dt class="hdlist1">
 1366 --walk-reflogs
 1367 </dt>
 1368 <dd>
 1369 <p>
 1370         Instead of walking the commit ancestry chain, walk
 1371         reflog entries from the most recent one to older ones.
 1372         When this option is used you cannot specify commits to
 1373         exclude (that is, <em>&#94;commit</em>, <em>commit1..commit2</em>,
 1374         and <em>commit1...commit2</em> notations cannot be used).
 1375 </p>
 1376 <div class="paragraph"><p>With <code>--pretty</code> format other than <code>oneline</code> (for obvious reasons),
 1377 this causes the output to have two extra lines of information
 1378 taken from the reflog.  The reflog designator in the output may be shown
 1379 as <code>ref@{Nth}</code> (where <code>Nth</code> is the reverse-chronological index in the
 1380 reflog) or as <code>ref@{timestamp}</code> (with the timestamp for that entry),
 1381 depending on a few rules:</p></div>
 1382 <div class="openblock">
 1383 <div class="content">
 1384 <div class="olist arabic"><ol class="arabic">
 1385 <li>
 1386 <p>
 1387 If the starting point is specified as <code>ref@{Nth}</code>, show the index
 1388 format.
 1389 </p>
 1390 </li>
 1391 <li>
 1392 <p>
 1393 If the starting point was specified as <code>ref@{now}</code>, show the
 1394 timestamp format.
 1395 </p>
 1396 </li>
 1397 <li>
 1398 <p>
 1399 If neither was used, but <code>--date</code> was given on the command line, show
 1400 the timestamp in the format requested by <code>--date</code>.
 1401 </p>
 1402 </li>
 1403 <li>
 1404 <p>
 1405 Otherwise, show the index format.
 1406 </p>
 1407 </li>
 1408 </ol></div>
 1409 </div></div>
 1410 <div class="paragraph"><p>Under <code>--pretty=oneline</code>, the commit message is
 1411 prefixed with this information on the same line.
 1412 This option cannot be combined with <code>--reverse</code>.
 1413 See also <a href="git-reflog.html">git-reflog(1)</a>.</p></div>
 1414 </dd>
 1415 <dt class="hdlist1">
 1416 --merge
 1417 </dt>
 1418 <dd>
 1419 <p>
 1420         After a failed merge, show refs that touch files having a
 1421         conflict and don&#8217;t exist on all heads to merge.
 1422 </p>
 1423 </dd>
 1424 <dt class="hdlist1">
 1425 --boundary
 1426 </dt>
 1427 <dd>
 1428 <p>
 1429         Output excluded boundary commits. Boundary commits are
 1430         prefixed with <code>-</code>.
 1431 </p>
 1432 </dd>
 1433 </dl></div>
 1434 </div></div>
 1435 </div>
 1436 <div class="sect2">
 1437 <h3 id="_history_simplification">History Simplification</h3>
 1438 <div class="paragraph"><p>Sometimes you are only interested in parts of the history, for example the
 1439 commits modifying a particular &lt;path&gt;. But there are two parts of
 1440 <em>History Simplification</em>, one part is selecting the commits and the other
 1441 is how to do it, as there are various strategies to simplify the history.</p></div>
 1442 <div class="paragraph"><p>The following options select the commits to be shown:</p></div>
 1443 <div class="dlist"><dl>
 1444 <dt class="hdlist1">
 1445 &lt;paths&gt;
 1446 </dt>
 1447 <dd>
 1448 <p>
 1449         Commits modifying the given &lt;paths&gt; are selected.
 1450 </p>
 1451 </dd>
 1452 <dt class="hdlist1">
 1453 --simplify-by-decoration
 1454 </dt>
 1455 <dd>
 1456 <p>
 1457         Commits that are referred by some branch or tag are selected.
 1458 </p>
 1459 </dd>
 1460 </dl></div>
 1461 <div class="paragraph"><p>Note that extra commits can be shown to give a meaningful history.</p></div>
 1462 <div class="paragraph"><p>The following options affect the way the simplification is performed:</p></div>
 1463 <div class="dlist"><dl>
 1464 <dt class="hdlist1">
 1465 Default mode
 1466 </dt>
 1467 <dd>
 1468 <p>
 1469         Simplifies the history to the simplest history explaining the
 1470         final state of the tree. Simplest because it prunes some side
 1471         branches if the end result is the same (i.e. merging branches
 1472         with the same content)
 1473 </p>
 1474 </dd>
 1475 <dt class="hdlist1">
 1476 --full-history
 1477 </dt>
 1478 <dd>
 1479 <p>
 1480         Same as the default mode, but does not prune some history.
 1481 </p>
 1482 </dd>
 1483 <dt class="hdlist1">
 1484 --dense
 1485 </dt>
 1486 <dd>
 1487 <p>
 1488         Only the selected commits are shown, plus some to have a
 1489         meaningful history.
 1490 </p>
 1491 </dd>
 1492 <dt class="hdlist1">
 1493 --sparse
 1494 </dt>
 1495 <dd>
 1496 <p>
 1497         All commits in the simplified history are shown.
 1498 </p>
 1499 </dd>
 1500 <dt class="hdlist1">
 1501 --simplify-merges
 1502 </dt>
 1503 <dd>
 1504 <p>
 1505         Additional option to <code>--full-history</code> to remove some needless
 1506         merges from the resulting history, as there are no selected
 1507         commits contributing to this merge.
 1508 </p>
 1509 </dd>
 1510 <dt class="hdlist1">
 1511 --ancestry-path
 1512 </dt>
 1513 <dd>
 1514 <p>
 1515         When given a range of commits to display (e.g. <em>commit1..commit2</em>
 1516         or <em>commit2 &#94;commit1</em>), only display commits that exist
 1517         directly on the ancestry chain between the <em>commit1</em> and
 1518         <em>commit2</em>, i.e. commits that are both descendants of <em>commit1</em>,
 1519         and ancestors of <em>commit2</em>.
 1520 </p>
 1521 </dd>
 1522 </dl></div>
 1523 <div class="paragraph"><p>A more detailed explanation follows.</p></div>
 1524 <div class="paragraph"><p>Suppose you specified <code>foo</code> as the &lt;paths&gt;.  We shall call commits
 1525 that modify <code>foo</code> !TREESAME, and the rest TREESAME.  (In a diff
 1526 filtered for <code>foo</code>, they look different and equal, respectively.)</p></div>
 1527 <div class="paragraph"><p>In the following, we will always refer to the same example history to
 1528 illustrate the differences between simplification settings.  We assume
 1529 that you are filtering for a file <code>foo</code> in this commit graph:</p></div>
 1530 <div class="listingblock">
 1531 <div class="content">
 1532 <pre><code>          .-A---M---N---O---P---Q
 1533          /     /   /   /   /   /
 1534         I     B   C   D   E   Y
 1535          \   /   /   /   /   /
 1536           `-------------'   X</code></pre>
 1537 </div></div>
 1538 <div class="paragraph"><p>The horizontal line of history A---Q is taken to be the first parent of
 1539 each merge.  The commits are:</p></div>
 1540 <div class="ulist"><ul>
 1541 <li>
 1542 <p>
 1543 <code>I</code> is the initial commit, in which <code>foo</code> exists with contents
 1544   &#8220;asdf&#8221;, and a file <code>quux</code> exists with contents &#8220;quux&#8221;. Initial
 1545   commits are compared to an empty tree, so <code>I</code> is !TREESAME.
 1546 </p>
 1547 </li>
 1548 <li>
 1549 <p>
 1550 In <code>A</code>, <code>foo</code> contains just &#8220;foo&#8221;.
 1551 </p>
 1552 </li>
 1553 <li>
 1554 <p>
 1555 <code>B</code> contains the same change as <code>A</code>.  Its merge <code>M</code> is trivial and
 1556   hence TREESAME to all parents.
 1557 </p>
 1558 </li>
 1559 <li>
 1560 <p>
 1561 <code>C</code> does not change <code>foo</code>, but its merge <code>N</code> changes it to &#8220;foobar&#8221;,
 1562   so it is not TREESAME to any parent.
 1563 </p>
 1564 </li>
 1565 <li>
 1566 <p>
 1567 <code>D</code> sets <code>foo</code> to &#8220;baz&#8221;. Its merge <code>O</code> combines the strings from
 1568   <code>N</code> and <code>D</code> to &#8220;foobarbaz&#8221;; i.e., it is not TREESAME to any parent.
 1569 </p>
 1570 </li>
 1571 <li>
 1572 <p>
 1573 <code>E</code> changes <code>quux</code> to &#8220;xyzzy&#8221;, and its merge <code>P</code> combines the
 1574   strings to &#8220;quux xyzzy&#8221;. <code>P</code> is TREESAME to <code>O</code>, but not to <code>E</code>.
 1575 </p>
 1576 </li>
 1577 <li>
 1578 <p>
 1579 <code>X</code> is an independent root commit that added a new file <code>side</code>, and <code>Y</code>
 1580   modified it. <code>Y</code> is TREESAME to <code>X</code>. Its merge <code>Q</code> added <code>side</code> to <code>P</code>, and
 1581   <code>Q</code> is TREESAME to <code>P</code>, but not to <code>Y</code>.
 1582 </p>
 1583 </li>
 1584 </ul></div>
 1585 <div class="paragraph"><p><code>rev-list</code> walks backwards through history, including or excluding
 1586 commits based on whether <code>--full-history</code> and/or parent rewriting
 1587 (via <code>--parents</code> or <code>--children</code>) are used. The following settings
 1588 are available.</p></div>
 1589 <div class="dlist"><dl>
 1590 <dt class="hdlist1">
 1591 Default mode
 1592 </dt>
 1593 <dd>
 1594 <p>
 1595         Commits are included if they are not TREESAME to any parent
 1596         (though this can be changed, see <code>--sparse</code> below).  If the
 1597         commit was a merge, and it was TREESAME to one parent, follow
 1598         only that parent.  (Even if there are several TREESAME
 1599         parents, follow only one of them.)  Otherwise, follow all
 1600         parents.
 1601 </p>
 1602 <div class="paragraph"><p>This results in:</p></div>
 1603 <div class="listingblock">
 1604 <div class="content">
 1605 <pre><code>          .-A---N---O
 1606          /     /   /
 1607         I---------D</code></pre>
 1608 </div></div>
 1609 <div class="paragraph"><p>Note how the rule to only follow the TREESAME parent, if one is
 1610 available, removed <code>B</code> from consideration entirely.  <code>C</code> was
 1611 considered via <code>N</code>, but is TREESAME.  Root commits are compared to an
 1612 empty tree, so <code>I</code> is !TREESAME.</p></div>
 1613 <div class="paragraph"><p>Parent/child relations are only visible with <code>--parents</code>, but that does
 1614 not affect the commits selected in default mode, so we have shown the
 1615 parent lines.</p></div>
 1616 </dd>
 1617 <dt class="hdlist1">
 1618 --full-history without parent rewriting
 1619 </dt>
 1620 <dd>
 1621 <p>
 1622         This mode differs from the default in one point: always follow
 1623         all parents of a merge, even if it is TREESAME to one of them.
 1624         Even if more than one side of the merge has commits that are
 1625         included, this does not imply that the merge itself is!  In
 1626         the example, we get
 1627 </p>
 1628 <div class="listingblock">
 1629 <div class="content">
 1630 <pre><code>        I  A  B  N  D  O  P  Q</code></pre>
 1631 </div></div>
 1632 <div class="paragraph"><p><code>M</code> was excluded because it is TREESAME to both parents.  <code>E</code>,
 1633 <code>C</code> and <code>B</code> were all walked, but only <code>B</code> was !TREESAME, so the others
 1634 do not appear.</p></div>
 1635 <div class="paragraph"><p>Note that without parent rewriting, it is not really possible to talk
 1636 about the parent/child relationships between the commits, so we show
 1637 them disconnected.</p></div>
 1638 </dd>
 1639 <dt class="hdlist1">
 1640 --full-history with parent rewriting
 1641 </dt>
 1642 <dd>
 1643 <p>
 1644         Ordinary commits are only included if they are !TREESAME
 1645         (though this can be changed, see <code>--sparse</code> below).
 1646 </p>
 1647 <div class="paragraph"><p>Merges are always included.  However, their parent list is rewritten:
 1648 Along each parent, prune away commits that are not included
 1649 themselves.  This results in</p></div>
 1650 <div class="listingblock">
 1651 <div class="content">
 1652 <pre><code>          .-A---M---N---O---P---Q
 1653          /     /   /   /   /
 1654         I     B   /   D   /
 1655          \   /   /   /   /
 1656           `-------------'</code></pre>
 1657 </div></div>
 1658 <div class="paragraph"><p>Compare to <code>--full-history</code> without rewriting above.  Note that <code>E</code>
 1659 was pruned away because it is TREESAME, but the parent list of P was
 1660 rewritten to contain <code>E</code>'s parent <code>I</code>.  The same happened for <code>C</code> and
 1661 <code>N</code>, and <code>X</code>, <code>Y</code> and <code>Q</code>.</p></div>
 1662 </dd>
 1663 </dl></div>
 1664 <div class="paragraph"><p>In addition to the above settings, you can change whether TREESAME
 1665 affects inclusion:</p></div>
 1666 <div class="dlist"><dl>
 1667 <dt class="hdlist1">
 1668 --dense
 1669 </dt>
 1670 <dd>
 1671 <p>
 1672         Commits that are walked are included if they are not TREESAME
 1673         to any parent.
 1674 </p>
 1675 </dd>
 1676 <dt class="hdlist1">
 1677 --sparse
 1678 </dt>
 1679 <dd>
 1680 <p>
 1681         All commits that are walked are included.
 1682 </p>
 1683 <div class="paragraph"><p>Note that without <code>--full-history</code>, this still simplifies merges: if
 1684 one of the parents is TREESAME, we follow only that one, so the other
 1685 sides of the merge are never walked.</p></div>
 1686 </dd>
 1687 <dt class="hdlist1">
 1688 --simplify-merges
 1689 </dt>
 1690 <dd>
 1691 <p>
 1692         First, build a history graph in the same way that
 1693         <code>--full-history</code> with parent rewriting does (see above).
 1694 </p>
 1695 <div class="paragraph"><p>Then simplify each commit <code>C</code> to its replacement <code>C'</code> in the final
 1696 history according to the following rules:</p></div>
 1697 <div class="openblock">
 1698 <div class="content">
 1699 <div class="ulist"><ul>
 1700 <li>
 1701 <p>
 1702 Set <code>C'</code> to <code>C</code>.
 1703 </p>
 1704 </li>
 1705 <li>
 1706 <p>
 1707 Replace each parent <code>P</code> of <code>C'</code> with its simplification <code>P'</code>.  In
 1708   the process, drop parents that are ancestors of other parents or that are
 1709   root commits TREESAME to an empty tree, and remove duplicates, but take care
 1710   to never drop all parents that we are TREESAME to.
 1711 </p>
 1712 </li>
 1713 <li>
 1714 <p>
 1715 If after this parent rewriting, <code>C'</code> is a root or merge commit (has
 1716   zero or &gt;1 parents), a boundary commit, or !TREESAME, it remains.
 1717   Otherwise, it is replaced with its only parent.
 1718 </p>
 1719 </li>
 1720 </ul></div>
 1721 </div></div>
 1722 <div class="paragraph"><p>The effect of this is best shown by way of comparing to
 1723 <code>--full-history</code> with parent rewriting.  The example turns into:</p></div>
 1724 <div class="listingblock">
 1725 <div class="content">
 1726 <pre><code>          .-A---M---N---O
 1727          /     /       /
 1728         I     B       D
 1729          \   /       /
 1730           `---------'</code></pre>
 1731 </div></div>
 1732 <div class="paragraph"><p>Note the major differences in <code>N</code>, <code>P</code>, and <code>Q</code> over <code>--full-history</code>:</p></div>
 1733 <div class="openblock">
 1734 <div class="content">
 1735 <div class="ulist"><ul>
 1736 <li>
 1737 <p>
 1738 <code>N</code>'s parent list had <code>I</code> removed, because it is an ancestor of the
 1739   other parent <code>M</code>.  Still, <code>N</code> remained because it is !TREESAME.
 1740 </p>
 1741 </li>
 1742 <li>
 1743 <p>
 1744 <code>P</code>'s parent list similarly had <code>I</code> removed.  <code>P</code> was then
 1745   removed completely, because it had one parent and is TREESAME.
 1746 </p>
 1747 </li>
 1748 <li>
 1749 <p>
 1750 <code>Q</code>'s parent list had <code>Y</code> simplified to <code>X</code>. <code>X</code> was then removed, because it
 1751   was a TREESAME root. <code>Q</code> was then removed completely, because it had one
 1752   parent and is TREESAME.
 1753 </p>
 1754 </li>
 1755 </ul></div>
 1756 </div></div>
 1757 </dd>
 1758 </dl></div>
 1759 <div class="paragraph"><p>Finally, there is a fifth simplification mode available:</p></div>
 1760 <div class="dlist"><dl>
 1761 <dt class="hdlist1">
 1762 --ancestry-path
 1763 </dt>
 1764 <dd>
 1765 <p>
 1766         Limit the displayed commits to those directly on the ancestry
 1767         chain between the &#8220;from&#8221; and &#8220;to&#8221; commits in the given commit
 1768         range. I.e. only display commits that are ancestor of the &#8220;to&#8221;
 1769         commit and descendants of the &#8220;from&#8221; commit.
 1770 </p>
 1771 <div class="paragraph"><p>As an example use case, consider the following commit history:</p></div>
 1772 <div class="listingblock">
 1773 <div class="content">
 1774 <pre><code>            D---E-------F
 1775            /     \       \
 1776           B---C---G---H---I---J
 1777          /                     \
 1778         A-------K---------------L--M</code></pre>
 1779 </div></div>
 1780 <div class="paragraph"><p>A regular <em>D..M</em> computes the set of commits that are ancestors of <code>M</code>,
 1781 but excludes the ones that are ancestors of <code>D</code>. This is useful to see
 1782 what happened to the history leading to <code>M</code> since <code>D</code>, in the sense
 1783 that &#8220;what does <code>M</code> have that did not exist in <code>D</code>&#8221;. The result in this
 1784 example would be all the commits, except <code>A</code> and <code>B</code> (and <code>D</code> itself,
 1785 of course).</p></div>
 1786 <div class="paragraph"><p>When we want to find out what commits in <code>M</code> are contaminated with the
 1787 bug introduced by <code>D</code> and need fixing, however, we might want to view
 1788 only the subset of <em>D..M</em> that are actually descendants of <code>D</code>, i.e.
 1789 excluding <code>C</code> and <code>K</code>. This is exactly what the <code>--ancestry-path</code>
 1790 option does. Applied to the <em>D..M</em> range, it results in:</p></div>
 1791 <div class="listingblock">
 1792 <div class="content">
 1793 <pre><code>                E-------F
 1794                  \       \
 1795                   G---H---I---J
 1796                                \
 1797                                 L--M</code></pre>
 1798 </div></div>
 1799 </dd>
 1800 </dl></div>
 1801 <div class="paragraph"><p>The <code>--simplify-by-decoration</code> option allows you to view only the
 1802 big picture of the topology of the history, by omitting commits
 1803 that are not referenced by tags.  Commits are marked as !TREESAME
 1804 (in other words, kept after history simplification rules described
 1805 above) if (1) they are referenced by tags, or (2) they change the
 1806 contents of the paths given on the command line.  All other
 1807 commits are marked as TREESAME (subject to be simplified away).</p></div>
 1808 </div>
 1809 <div class="sect2">
 1810 <h3 id="_commit_ordering">Commit Ordering</h3>
 1811 <div class="paragraph"><p>By default, the commits are shown in reverse chronological order.</p></div>
 1812 <div class="dlist"><dl>
 1813 <dt class="hdlist1">
 1814 --date-order
 1815 </dt>
 1816 <dd>
 1817 <p>
 1818         Show no parents before all of its children are shown, but
 1819         otherwise show commits in the commit timestamp order.
 1820 </p>
 1821 </dd>
 1822 <dt class="hdlist1">
 1823 --author-date-order
 1824 </dt>
 1825 <dd>
 1826 <p>
 1827         Show no parents before all of its children are shown, but
 1828         otherwise show commits in the author timestamp order.
 1829 </p>
 1830 </dd>
 1831 <dt class="hdlist1">
 1832 --topo-order
 1833 </dt>
 1834 <dd>
 1835 <p>
 1836         Show no parents before all of its children are shown, and
 1837         avoid showing commits on multiple lines of history
 1838         intermixed.
 1839 </p>
 1840 <div class="paragraph"><p>For example, in a commit history like this:</p></div>
 1841 <div class="listingblock">
 1842 <div class="content">
 1843 <pre><code>    ---1----2----4----7
 1844         \              \
 1845          3----5----6----8---</code></pre>
 1846 </div></div>
 1847 <div class="paragraph"><p>where the numbers denote the order of commit timestamps, <code>git
 1848 rev-list</code> and friends with <code>--date-order</code> show the commits in the
 1849 timestamp order: 8 7 6 5 4 3 2 1.</p></div>
 1850 <div class="paragraph"><p>With <code>--topo-order</code>, they would show 8 6 5 3 7 4 2 1 (or 8 7 4 2 6 5
 1851 3 1); some older commits are shown before newer ones in order to
 1852 avoid showing the commits from two parallel development track mixed
 1853 together.</p></div>
 1854 </dd>
 1855 <dt class="hdlist1">
 1856 --reverse
 1857 </dt>
 1858 <dd>
 1859 <p>
 1860         Output the commits chosen to be shown (see Commit Limiting
 1861         section above) in reverse order. Cannot be combined with
 1862         <code>--walk-reflogs</code>.
 1863 </p>
 1864 </dd>
 1865 </dl></div>
 1866 </div>
 1867 <div class="sect2">
 1868 <h3 id="_object_traversal">Object Traversal</h3>
 1869 <div class="paragraph"><p>These options are mostly targeted for packing of Git repositories.</p></div>
 1870 <div class="dlist"><dl>
 1871 <dt class="hdlist1">
 1872 --no-walk[=(sorted|unsorted)]
 1873 </dt>
 1874 <dd>
 1875 <p>
 1876         Only show the given commits, but do not traverse their ancestors.
 1877         This has no effect if a range is specified. If the argument
 1878         <code>unsorted</code> is given, the commits are shown in the order they were
 1879         given on the command line. Otherwise (if <code>sorted</code> or no argument
 1880         was given), the commits are shown in reverse chronological order
 1881         by commit time.
 1882         Cannot be combined with <code>--graph</code>.
 1883 </p>
 1884 </dd>
 1885 <dt class="hdlist1">
 1886 --do-walk
 1887 </dt>
 1888 <dd>
 1889 <p>
 1890         Overrides a previous <code>--no-walk</code>.
 1891 </p>
 1892 </dd>
 1893 </dl></div>
 1894 </div>
 1895 <div class="sect2">
 1896 <h3 id="_commit_formatting">Commit Formatting</h3>
 1897 <div class="dlist"><dl>
 1898 <dt class="hdlist1">
 1899 --pretty[=&lt;format&gt;]
 1900 </dt>
 1901 <dt class="hdlist1">
 1902 --format=&lt;format&gt;
 1903 </dt>
 1904 <dd>
 1905 <p>
 1906         Pretty-print the contents of the commit logs in a given format,
 1907         where <em>&lt;format&gt;</em> can be one of <em>oneline</em>, <em>short</em>, <em>medium</em>,
 1908         <em>full</em>, <em>fuller</em>, <em>email</em>, <em>raw</em>, <em>format:&lt;string&gt;</em>
 1909         and <em>tformat:&lt;string&gt;</em>.  When <em>&lt;format&gt;</em> is none of the above,
 1910         and has <em>%placeholder</em> in it, it acts as if
 1911         <em>--pretty=tformat:&lt;format&gt;</em> were given.
 1912 </p>
 1913 <div class="paragraph"><p>See the "PRETTY FORMATS" section for some additional details for each
 1914 format.  When <em>=&lt;format&gt;</em> part is omitted, it defaults to <em>medium</em>.</p></div>
 1915 <div class="paragraph"><p>Note: you can specify the default pretty format in the repository
 1916 configuration (see <a href="git-config.html">git-config(1)</a>).</p></div>
 1917 </dd>
 1918 <dt class="hdlist1">
 1919 --abbrev-commit
 1920 </dt>
 1921 <dd>
 1922 <p>
 1923         Instead of showing the full 40-byte hexadecimal commit object
 1924         name, show only a partial prefix.  Non default number of
 1925         digits can be specified with "--abbrev=&lt;n&gt;" (which also modifies
 1926         diff output, if it is displayed).
 1927 </p>
 1928 <div class="paragraph"><p>This should make "--pretty=oneline" a whole lot more readable for
 1929 people using 80-column terminals.</p></div>
 1930 </dd>
 1931 <dt class="hdlist1">
 1932 --no-abbrev-commit
 1933 </dt>
 1934 <dd>
 1935 <p>
 1936         Show the full 40-byte hexadecimal commit object name. This negates
 1937         <code>--abbrev-commit</code> and those options which imply it such as
 1938         "--oneline". It also overrides the <code>log.abbrevCommit</code> variable.
 1939 </p>
 1940 </dd>
 1941 <dt class="hdlist1">
 1942 --oneline
 1943 </dt>
 1944 <dd>
 1945 <p>
 1946         This is a shorthand for "--pretty=oneline --abbrev-commit"
 1947         used together.
 1948 </p>
 1949 </dd>
 1950 <dt class="hdlist1">
 1951 --encoding=&lt;encoding&gt;
 1952 </dt>
 1953 <dd>
 1954 <p>
 1955         The commit objects record the encoding used for the log message
 1956         in their encoding header; this option can be used to tell the
 1957         command to re-code the commit log message in the encoding
 1958         preferred by the user.  For non plumbing commands this
 1959         defaults to UTF-8. Note that if an object claims to be encoded
 1960         in <code>X</code> and we are outputting in <code>X</code>, we will output the object
 1961         verbatim; this means that invalid sequences in the original
 1962         commit may be copied to the output.
 1963 </p>
 1964 </dd>
 1965 <dt class="hdlist1">
 1966 --expand-tabs=&lt;n&gt;
 1967 </dt>
 1968 <dt class="hdlist1">
 1969 --expand-tabs
 1970 </dt>
 1971 <dt class="hdlist1">
 1972 --no-expand-tabs
 1973 </dt>
 1974 <dd>
 1975 <p>
 1976         Perform a tab expansion (replace each tab with enough spaces
 1977         to fill to the next display column that is multiple of <em>&lt;n&gt;</em>)
 1978         in the log message before showing it in the output.
 1979         <code>--expand-tabs</code> is a short-hand for <code>--expand-tabs=8</code>, and
 1980         <code>--no-expand-tabs</code> is a short-hand for <code>--expand-tabs=0</code>,
 1981         which disables tab expansion.
 1982 </p>
 1983 <div class="paragraph"><p>By default, tabs are expanded in pretty formats that indent the log
 1984 message by 4 spaces (i.e.  <em>medium</em>, which is the default, <em>full</em>,
 1985 and <em>fuller</em>).</p></div>
 1986 </dd>
 1987 <dt class="hdlist1">
 1988 --notes[=&lt;treeish&gt;]
 1989 </dt>
 1990 <dd>
 1991 <p>
 1992         Show the notes (see <a href="git-notes.html">git-notes(1)</a>) that annotate the
 1993         commit, when showing the commit log message.  This is the default
 1994         for <code>git log</code>, <code>git show</code> and <code>git whatchanged</code> commands when
 1995         there is no <code>--pretty</code>, <code>--format</code>, or <code>--oneline</code> option given
 1996         on the command line.
 1997 </p>
 1998 <div class="paragraph"><p>By default, the notes shown are from the notes refs listed in the
 1999 <code>core.notesRef</code> and <code>notes.displayRef</code> variables (or corresponding
 2000 environment overrides). See <a href="git-config.html">git-config(1)</a> for more details.</p></div>
 2001 <div class="paragraph"><p>With an optional <em>&lt;treeish&gt;</em> argument, use the treeish to find the notes
 2002 to display.  The treeish can specify the full refname when it begins
 2003 with <code>refs/notes/</code>; when it begins with <code>notes/</code>, <code>refs/</code> and otherwise
 2004 <code>refs/notes/</code> is prefixed to form a full name of the ref.</p></div>
 2005 <div class="paragraph"><p>Multiple --notes options can be combined to control which notes are
 2006 being displayed. Examples: "--notes=foo" will show only notes from
 2007 "refs/notes/foo"; "--notes=foo --notes" will show both notes from
 2008 "refs/notes/foo" and from the default notes ref(s).</p></div>
 2009 </dd>
 2010 <dt class="hdlist1">
 2011 --no-notes
 2012 </dt>
 2013 <dd>
 2014 <p>
 2015         Do not show notes. This negates the above <code>--notes</code> option, by
 2016         resetting the list of notes refs from which notes are shown.
 2017         Options are parsed in the order given on the command line, so e.g.
 2018         "--notes --notes=foo --no-notes --notes=bar" will only show notes
 2019         from "refs/notes/bar".
 2020 </p>
 2021 </dd>
 2022 <dt class="hdlist1">
 2023 --show-notes[=&lt;treeish&gt;]
 2024 </dt>
 2025 <dt class="hdlist1">
 2026 --[no-]standard-notes
 2027 </dt>
 2028 <dd>
 2029 <p>
 2030         These options are deprecated. Use the above --notes/--no-notes
 2031         options instead.
 2032 </p>
 2033 </dd>
 2034 <dt class="hdlist1">
 2035 --show-signature
 2036 </dt>
 2037 <dd>
 2038 <p>
 2039         Check the validity of a signed commit object by passing the signature
 2040         to <code>gpg --verify</code> and show the output.
 2041 </p>
 2042 </dd>
 2043 <dt class="hdlist1">
 2044 --relative-date
 2045 </dt>
 2046 <dd>
 2047 <p>
 2048         Synonym for <code>--date=relative</code>.
 2049 </p>
 2050 </dd>
 2051 <dt class="hdlist1">
 2052 --date=&lt;format&gt;
 2053 </dt>
 2054 <dd>
 2055 <p>
 2056         Only takes effect for dates shown in human-readable format, such
 2057         as when using <code>--pretty</code>. <code>log.date</code> config variable sets a default
 2058         value for the log command&#8217;s <code>--date</code> option. By default, dates
 2059         are shown in the original time zone (either committer&#8217;s or
 2060         author&#8217;s). If <code>-local</code> is appended to the format (e.g.,
 2061         <code>iso-local</code>), the user&#8217;s local time zone is used instead.
 2062 </p>
 2063 <div class="paragraph"><p><code>--date=relative</code> shows dates relative to the current time,
 2064 e.g. &#8220;2 hours ago&#8221;. The <code>-local</code> option has no effect for
 2065 <code>--date=relative</code>.</p></div>
 2066 <div class="paragraph"><p><code>--date=local</code> is an alias for <code>--date=default-local</code>.</p></div>
 2067 <div class="paragraph"><p><code>--date=iso</code> (or <code>--date=iso8601</code>) shows timestamps in a ISO 8601-like format.
 2068 The differences to the strict ISO 8601 format are:</p></div>
 2069 <div class="ulist"><ul>
 2070 <li>
 2071 <p>
 2072 a space instead of the <code>T</code> date/time delimiter
 2073 </p>
 2074 </li>
 2075 <li>
 2076 <p>
 2077 a space between time and time zone
 2078 </p>
 2079 </li>
 2080 <li>
 2081 <p>
 2082 no colon between hours and minutes of the time zone
 2083 </p>
 2084 </li>
 2085 </ul></div>
 2086 <div class="paragraph"><p><code>--date=iso-strict</code> (or <code>--date=iso8601-strict</code>) shows timestamps in strict
 2087 ISO 8601 format.</p></div>
 2088 <div class="paragraph"><p><code>--date=rfc</code> (or <code>--date=rfc2822</code>) shows timestamps in RFC 2822
 2089 format, often found in email messages.</p></div>
 2090 <div class="paragraph"><p><code>--date=short</code> shows only the date, but not the time, in <code>YYYY-MM-DD</code> format.</p></div>
 2091 <div class="paragraph"><p><code>--date=raw</code> shows the date as seconds since the epoch (1970-01-01
 2092 00:00:00 UTC), followed by a space, and then the timezone as an offset
 2093 from UTC (a <code>+</code> or <code>-</code> with four digits; the first two are hours, and
 2094 the second two are minutes). I.e., as if the timestamp were formatted
 2095 with <code>strftime("%s %z")</code>).
 2096 Note that the <code>-local</code> option does not affect the seconds-since-epoch
 2097 value (which is always measured in UTC), but does switch the accompanying
 2098 timezone value.</p></div>
 2099 <div class="paragraph"><p><code>--date=unix</code> shows the date as a Unix epoch timestamp (seconds since
 2100 1970).  As with <code>--raw</code>, this is always in UTC and therefore <code>-local</code>
 2101 has no effect.</p></div>
 2102 <div class="paragraph"><p><code>--date=format:...</code> feeds the format <code>...</code> to your system <code>strftime</code>,
 2103 except for %z and %Z, which are handled internally.
 2104 Use <code>--date=format:%c</code> to show the date in your system locale&#8217;s
 2105 preferred format.  See the <code>strftime</code> manual for a complete list of
 2106 format placeholders. When using <code>-local</code>, the correct syntax is
 2107 <code>--date=format-local:...</code>.</p></div>
 2108 <div class="paragraph"><p><code>--date=default</code> is the default format, and is similar to
 2109 <code>--date=rfc2822</code>, with a few exceptions:</p></div>
 2110 <div class="ulist"><ul>
 2111 <li>
 2112 <p>
 2113 there is no comma after the day-of-week
 2114 </p>
 2115 </li>
 2116 <li>
 2117 <p>
 2118 the time zone is omitted when the local time zone is used
 2119 </p>
 2120 </li>
 2121 </ul></div>
 2122 </dd>
 2123 <dt class="hdlist1">
 2124 --parents
 2125 </dt>
 2126 <dd>
 2127 <p>
 2128         Print also the parents of the commit (in the form "commit parent&#8230;").
 2129         Also enables parent rewriting, see <em>History Simplification</em> above.
 2130 </p>
 2131 </dd>
 2132 <dt class="hdlist1">
 2133 --children
 2134 </dt>
 2135 <dd>
 2136 <p>
 2137         Print also the children of the commit (in the form "commit child&#8230;").
 2138         Also enables parent rewriting, see <em>History Simplification</em> above.
 2139 </p>
 2140 </dd>
 2141 <dt class="hdlist1">
 2142 --left-right
 2143 </dt>
 2144 <dd>
 2145 <p>
 2146         Mark which side of a symmetric difference a commit is reachable from.
 2147         Commits from the left side are prefixed with <code>&lt;</code> and those from
 2148         the right with <code>&gt;</code>.  If combined with <code>--boundary</code>, those
 2149         commits are prefixed with <code>-</code>.
 2150 </p>
 2151 <div class="paragraph"><p>For example, if you have this topology:</p></div>
 2152 <div class="listingblock">
 2153 <div class="content">
 2154 <pre><code>             y---b---b  branch B
 2155             / \ /
 2156            /   .
 2157           /   / \
 2158          o---x---a---a  branch A</code></pre>
 2159 </div></div>
 2160 <div class="paragraph"><p>you would get an output like this:</p></div>
 2161 <div class="listingblock">
 2162 <div class="content">
 2163 <pre><code>        $ git rev-list --left-right --boundary --pretty=oneline A...B
 2164 
 2165         &gt;bbbbbbb... 3rd on b
 2166         &gt;bbbbbbb... 2nd on b
 2167         &lt;aaaaaaa... 3rd on a
 2168         &lt;aaaaaaa... 2nd on a
 2169         -yyyyyyy... 1st on b
 2170         -xxxxxxx... 1st on a</code></pre>
 2171 </div></div>
 2172 </dd>
 2173 <dt class="hdlist1">
 2174 --graph
 2175 </dt>
 2176 <dd>
 2177 <p>
 2178         Draw a text-based graphical representation of the commit history
 2179         on the left hand side of the output.  This may cause extra lines
 2180         to be printed in between commits, in order for the graph history
 2181         to be drawn properly.
 2182         Cannot be combined with <code>--no-walk</code>.
 2183 </p>
 2184 <div class="paragraph"><p>This enables parent rewriting, see <em>History Simplification</em> above.</p></div>
 2185 <div class="paragraph"><p>This implies the <code>--topo-order</code> option by default, but the
 2186 <code>--date-order</code> option may also be specified.</p></div>
 2187 </dd>
 2188 <dt class="hdlist1">
 2189 --show-linear-break[=&lt;barrier&gt;]
 2190 </dt>
 2191 <dd>
 2192 <p>
 2193         When --graph is not used, all history branches are flattened
 2194         which can make it hard to see that the two consecutive commits
 2195         do not belong to a linear branch. This option puts a barrier
 2196         in between them in that case. If <code>&lt;barrier&gt;</code> is specified, it
 2197         is the string that will be shown instead of the default one.
 2198 </p>
 2199 </dd>
 2200 </dl></div>
 2201 </div>
 2202 <div class="sect2">
 2203 <h3 id="_diff_formatting">Diff Formatting</h3>
 2204 <div class="paragraph"><p>Listed below are options that control the formatting of diff output.
 2205 Some of them are specific to <a href="git-rev-list.html">git-rev-list(1)</a>, however other diff
 2206 options may be given. See <a href="git-diff-files.html">git-diff-files(1)</a> for more options.</p></div>
 2207 <div class="dlist"><dl>
 2208 <dt class="hdlist1">
 2209 -c
 2210 </dt>
 2211 <dd>
 2212 <p>
 2213         With this option, diff output for a merge commit
 2214         shows the differences from each of the parents to the merge result
 2215         simultaneously instead of showing pairwise diff between a parent
 2216         and the result one at a time. Furthermore, it lists only files
 2217         which were modified from all parents.
 2218 </p>
 2219 </dd>
 2220 <dt class="hdlist1">
 2221 --cc
 2222 </dt>
 2223 <dd>
 2224 <p>
 2225         This flag implies the <code>-c</code> option and further compresses the
 2226         patch output by omitting uninteresting hunks whose contents in
 2227         the parents have only two variants and the merge result picks
 2228         one of them without modification.
 2229 </p>
 2230 </dd>
 2231 <dt class="hdlist1">
 2232 -m
 2233 </dt>
 2234 <dd>
 2235 <p>
 2236         This flag makes the merge commits show the full diff like
 2237         regular commits; for each merge parent, a separate log entry
 2238         and diff is generated. An exception is that only diff against
 2239         the first parent is shown when <code>--first-parent</code> option is given;
 2240         in that case, the output represents the changes the merge
 2241         brought <em>into</em> the then-current branch.
 2242 </p>
 2243 </dd>
 2244 <dt class="hdlist1">
 2245 -r
 2246 </dt>
 2247 <dd>
 2248 <p>
 2249         Show recursive diffs.
 2250 </p>
 2251 </dd>
 2252 <dt class="hdlist1">
 2253 -t
 2254 </dt>
 2255 <dd>
 2256 <p>
 2257         Show the tree objects in the diff output. This implies <code>-r</code>.
 2258 </p>
 2259 </dd>
 2260 </dl></div>
 2261 </div>
 2262 </div>
 2263 </div>
 2264 <div class="sect1">
 2265 <h2 id="_pretty_formats">PRETTY FORMATS</h2>
 2266 <div class="sectionbody">
 2267 <div class="paragraph"><p>If the commit is a merge, and if the pretty-format
 2268 is not <em>oneline</em>, <em>email</em> or <em>raw</em>, an additional line is
 2269 inserted before the <em>Author:</em> line.  This line begins with
 2270 "Merge: " and the sha1s of ancestral commits are printed,
 2271 separated by spaces.  Note that the listed commits may not
 2272 necessarily be the list of the <strong>direct</strong> parent commits if you
 2273 have limited your view of history: for example, if you are
 2274 only interested in changes related to a certain directory or
 2275 file.</p></div>
 2276 <div class="paragraph"><p>There are several built-in formats, and you can define
 2277 additional formats by setting a pretty.&lt;name&gt;
 2278 config option to either another format name, or a
 2279 <em>format:</em> string, as described below (see
 2280 <a href="git-config.html">git-config(1)</a>). Here are the details of the
 2281 built-in formats:</p></div>
 2282 <div class="ulist"><ul>
 2283 <li>
 2284 <p>
 2285 <em>oneline</em>
 2286 </p>
 2287 <div class="literalblock">
 2288 <div class="content">
 2289 <pre><code>&lt;sha1&gt; &lt;title line&gt;</code></pre>
 2290 </div></div>
 2291 <div class="paragraph"><p>This is designed to be as compact as possible.</p></div>
 2292 </li>
 2293 <li>
 2294 <p>
 2295 <em>short</em>
 2296 </p>
 2297 <div class="literalblock">
 2298 <div class="content">
 2299 <pre><code>commit &lt;sha1&gt;
 2300 Author: &lt;author&gt;</code></pre>
 2301 </div></div>
 2302 <div class="literalblock">
 2303 <div class="content">
 2304 <pre><code>&lt;title line&gt;</code></pre>
 2305 </div></div>
 2306 </li>
 2307 <li>
 2308 <p>
 2309 <em>medium</em>
 2310 </p>
 2311 <div class="literalblock">
 2312 <div class="content">
 2313 <pre><code>commit &lt;sha1&gt;
 2314 Author: &lt;author&gt;
 2315 Date:   &lt;author date&gt;</code></pre>
 2316 </div></div>
 2317 <div class="literalblock">
 2318 <div class="content">
 2319 <pre><code>&lt;title line&gt;</code></pre>
 2320 </div></div>
 2321 <div class="literalblock">
 2322 <div class="content">
 2323 <pre><code>&lt;full commit message&gt;</code></pre>
 2324 </div></div>
 2325 </li>
 2326 <li>
 2327 <p>
 2328 <em>full</em>
 2329 </p>
 2330 <div class="literalblock">
 2331 <div class="content">
 2332 <pre><code>commit &lt;sha1&gt;
 2333 Author: &lt;author&gt;
 2334 Commit: &lt;committer&gt;</code></pre>
 2335 </div></div>
 2336 <div class="literalblock">
 2337 <div class="content">
 2338 <pre><code>&lt;title line&gt;</code></pre>
 2339 </div></div>
 2340 <div class="literalblock">
 2341 <div class="content">
 2342 <pre><code>&lt;full commit message&gt;</code></pre>
 2343 </div></div>
 2344 </li>
 2345 <li>
 2346 <p>
 2347 <em>fuller</em>
 2348 </p>
 2349 <div class="literalblock">
 2350 <div class="content">
 2351 <pre><code>commit &lt;sha1&gt;
 2352 Author:     &lt;author&gt;
 2353 AuthorDate: &lt;author date&gt;
 2354 Commit:     &lt;committer&gt;
 2355 CommitDate: &lt;committer date&gt;</code></pre>
 2356 </div></div>
 2357 <div class="literalblock">
 2358 <div class="content">
 2359 <pre><code>&lt;title line&gt;</code></pre>
 2360 </div></div>
 2361 <div class="literalblock">
 2362 <div class="content">
 2363 <pre><code>&lt;full commit message&gt;</code></pre>
 2364 </div></div>
 2365 </li>
 2366 <li>
 2367 <p>
 2368 <em>email</em>
 2369 </p>
 2370 <div class="literalblock">
 2371 <div class="content">
 2372 <pre><code>From &lt;sha1&gt; &lt;date&gt;
 2373 From: &lt;author&gt;
 2374 Date: &lt;author date&gt;
 2375 Subject: [PATCH] &lt;title line&gt;</code></pre>
 2376 </div></div>
 2377 <div class="literalblock">
 2378 <div class="content">
 2379 <pre><code>&lt;full commit message&gt;</code></pre>
 2380 </div></div>
 2381 </li>
 2382 <li>
 2383 <p>
 2384 <em>raw</em>
 2385 </p>
 2386 <div class="paragraph"><p>The <em>raw</em> format shows the entire commit exactly as
 2387 stored in the commit object.  Notably, the SHA-1s are
 2388 displayed in full, regardless of whether --abbrev or
 2389 --no-abbrev are used, and <em>parents</em> information show the
 2390 true parent commits, without taking grafts or history
 2391 simplification into account. Note that this format affects the way
 2392 commits are displayed, but not the way the diff is shown e.g. with
 2393 <code>git log --raw</code>. To get full object names in a raw diff format,
 2394 use <code>--no-abbrev</code>.</p></div>
 2395 </li>
 2396 <li>
 2397 <p>
 2398 <em>format:&lt;string&gt;</em>
 2399 </p>
 2400 <div class="paragraph"><p>The <em>format:&lt;string&gt;</em> format allows you to specify which information
 2401 you want to show. It works a little bit like printf format,
 2402 with the notable exception that you get a newline with <em>%n</em>
 2403 instead of <em>\n</em>.</p></div>
 2404 <div class="paragraph"><p>E.g, <em>format:"The author of %h was %an, %ar%nThe title was &gt;&gt;%s&lt;&lt;%n"</em>
 2405 would show something like this:</p></div>
 2406 <div class="listingblock">
 2407 <div class="content">
 2408 <pre><code>The author of fe6e0ee was Junio C Hamano, 23 hours ago
 2409 The title was &gt;&gt;t4119: test autocomputing -p&lt;n&gt; for traditional diff input.&lt;&lt;</code></pre>
 2410 </div></div>
 2411 <div class="paragraph"><p>The placeholders are:</p></div>
 2412 <div class="ulist"><ul>
 2413 <li>
 2414 <p>
 2415 <em>%H</em>: commit hash
 2416 </p>
 2417 </li>
 2418 <li>
 2419 <p>
 2420 <em>%h</em>: abbreviated commit hash
 2421 </p>
 2422 </li>
 2423 <li>
 2424 <p>
 2425 <em>%T</em>: tree hash
 2426 </p>
 2427 </li>
 2428 <li>
 2429 <p>
 2430 <em>%t</em>: abbreviated tree hash
 2431 </p>
 2432 </li>
 2433 <li>
 2434 <p>
 2435 <em>%P</em>: parent hashes
 2436 </p>
 2437 </li>
 2438 <li>
 2439 <p>
 2440 <em>%p</em>: abbreviated parent hashes
 2441 </p>
 2442 </li>
 2443 <li>
 2444 <p>
 2445 <em>%an</em>: author name
 2446 </p>
 2447 </li>
 2448 <li>
 2449 <p>
 2450 <em>%aN</em>: author name (respecting .mailmap, see <a href="git-shortlog.html">git-shortlog(1)</a>
 2451   or <a href="git-blame.html">git-blame(1)</a>)
 2452 </p>
 2453 </li>
 2454 <li>
 2455 <p>
 2456 <em>%ae</em>: author email
 2457 </p>
 2458 </li>
 2459 <li>
 2460 <p>
 2461 <em>%aE</em>: author email (respecting .mailmap, see
 2462   <a href="git-shortlog.html">git-shortlog(1)</a> or <a href="git-blame.html">git-blame(1)</a>)
 2463 </p>
 2464 </li>
 2465 <li>
 2466 <p>
 2467 <em>%ad</em>: author date (format respects --date= option)
 2468 </p>
 2469 </li>
 2470 <li>
 2471 <p>
 2472 <em>%aD</em>: author date, RFC2822 style
 2473 </p>
 2474 </li>
 2475 <li>
 2476 <p>
 2477 <em>%ar</em>: author date, relative
 2478 </p>
 2479 </li>
 2480 <li>
 2481 <p>
 2482 <em>%at</em>: author date, UNIX timestamp
 2483 </p>
 2484 </li>
 2485 <li>
 2486 <p>
 2487 <em>%ai</em>: author date, ISO 8601-like format
 2488 </p>
 2489 </li>
 2490 <li>
 2491 <p>
 2492 <em>%aI</em>: author date, strict ISO 8601 format
 2493 </p>
 2494 </li>
 2495 <li>
 2496 <p>
 2497 <em>%cn</em>: committer name
 2498 </p>
 2499 </li>
 2500 <li>
 2501 <p>
 2502 <em>%cN</em>: committer name (respecting .mailmap, see
 2503   <a href="git-shortlog.html">git-shortlog(1)</a> or <a href="git-blame.html">git-blame(1)</a>)
 2504 </p>
 2505 </li>
 2506 <li>
 2507 <p>
 2508 <em>%ce</em>: committer email
 2509 </p>
 2510 </li>
 2511 <li>
 2512 <p>
 2513 <em>%cE</em>: committer email (respecting .mailmap, see
 2514   <a href="git-shortlog.html">git-shortlog(1)</a> or <a href="git-blame.html">git-blame(1)</a>)
 2515 </p>
 2516 </li>
 2517 <li>
 2518 <p>
 2519 <em>%cd</em>: committer date (format respects --date= option)
 2520 </p>
 2521 </li>
 2522 <li>
 2523 <p>
 2524 <em>%cD</em>: committer date, RFC2822 style
 2525 </p>
 2526 </li>
 2527 <li>
 2528 <p>
 2529 <em>%cr</em>: committer date, relative
 2530 </p>
 2531 </li>
 2532 <li>
 2533 <p>
 2534 <em>%ct</em>: committer date, UNIX timestamp
 2535 </p>
 2536 </li>
 2537 <li>
 2538 <p>
 2539 <em>%ci</em>: committer date, ISO 8601-like format
 2540 </p>
 2541 </li>
 2542 <li>
 2543 <p>
 2544 <em>%cI</em>: committer date, strict ISO 8601 format
 2545 </p>
 2546 </li>
 2547 <li>
 2548 <p>
 2549 <em>%d</em>: ref names, like the --decorate option of <a href="git-log.html">git-log(1)</a>
 2550 </p>
 2551 </li>
 2552 <li>
 2553 <p>
 2554 <em>%D</em>: ref names without the " (", ")" wrapping.
 2555 </p>
 2556 </li>
 2557 <li>
 2558 <p>
 2559 <em>%e</em>: encoding
 2560 </p>
 2561 </li>
 2562 <li>
 2563 <p>
 2564 <em>%s</em>: subject
 2565 </p>
 2566 </li>
 2567 <li>
 2568 <p>
 2569 <em>%f</em>: sanitized subject line, suitable for a filename
 2570 </p>
 2571 </li>
 2572 <li>
 2573 <p>
 2574 <em>%b</em>: body
 2575 </p>
 2576 </li>
 2577 <li>
 2578 <p>
 2579 <em>%B</em>: raw body (unwrapped subject and body)
 2580 </p>
 2581 </li>
 2582 <li>
 2583 <p>
 2584 <em>%N</em>: commit notes
 2585 </p>
 2586 </li>
 2587 <li>
 2588 <p>
 2589 <em>%GG</em>: raw verification message from GPG for a signed commit
 2590 </p>
 2591 </li>
 2592 <li>
 2593 <p>
 2594 <em>%G?</em>: show "G" for a good (valid) signature,
 2595   "B" for a bad signature,
 2596   "U" for a good signature with unknown validity,
 2597   "X" for a good signature that has expired,
 2598   "Y" for a good signature made by an expired key,
 2599   "R" for a good signature made by a revoked key,
 2600   "E" if the signature cannot be checked (e.g. missing key)
 2601   and "N" for no signature
 2602 </p>
 2603 </li>
 2604 <li>
 2605 <p>
 2606 <em>%GS</em>: show the name of the signer for a signed commit
 2607 </p>
 2608 </li>
 2609 <li>
 2610 <p>
 2611 <em>%GK</em>: show the key used to sign a signed commit
 2612 </p>
 2613 </li>
 2614 <li>
 2615 <p>
 2616 <em>%GF</em>: show the fingerprint of the key used to sign a signed commit
 2617 </p>
 2618 </li>
 2619 <li>
 2620 <p>
 2621 <em>%GP</em>: show the fingerprint of the primary key whose subkey was used
 2622   to sign a signed commit
 2623 </p>
 2624 </li>
 2625 <li>
 2626 <p>
 2627 <em>%gD</em>: reflog selector, e.g., <code>refs/stash@{1}</code> or
 2628   <code>refs/stash@{2 minutes ago</code>}; the format follows the rules described
 2629   for the <code>-g</code> option. The portion before the <code>@</code> is the refname as
 2630   given on the command line (so <code>git log -g refs/heads/master</code> would
 2631   yield <code>refs/heads/master@{0}</code>).
 2632 </p>
 2633 </li>
 2634 <li>
 2635 <p>
 2636 <em>%gd</em>: shortened reflog selector; same as <code>%gD</code>, but the refname
 2637   portion is shortened for human readability (so <code>refs/heads/master</code>
 2638   becomes just <code>master</code>).
 2639 </p>
 2640 </li>
 2641 <li>
 2642 <p>
 2643 <em>%gn</em>: reflog identity name
 2644 </p>
 2645 </li>
 2646 <li>
 2647 <p>
 2648 <em>%gN</em>: reflog identity name (respecting .mailmap, see
 2649   <a href="git-shortlog.html">git-shortlog(1)</a> or <a href="git-blame.html">git-blame(1)</a>)
 2650 </p>
 2651 </li>
 2652 <li>
 2653 <p>
 2654 <em>%ge</em>: reflog identity email
 2655 </p>
 2656 </li>
 2657 <li>
 2658 <p>
 2659 <em>%gE</em>: reflog identity email (respecting .mailmap, see
 2660   <a href="git-shortlog.html">git-shortlog(1)</a> or <a href="git-blame.html">git-blame(1)</a>)
 2661 </p>
 2662 </li>
 2663 <li>
 2664 <p>
 2665 <em>%gs</em>: reflog subject
 2666 </p>
 2667 </li>
 2668 <li>
 2669 <p>
 2670 <em>%Cred</em>: switch color to red
 2671 </p>
 2672 </li>
 2673 <li>
 2674 <p>
 2675 <em>%Cgreen</em>: switch color to green
 2676 </p>
 2677 </li>
 2678 <li>
 2679 <p>
 2680 <em>%Cblue</em>: switch color to blue
 2681 </p>
 2682 </li>
 2683 <li>
 2684 <p>
 2685 <em>%Creset</em>: reset color
 2686 </p>
 2687 </li>
 2688 <li>
 2689 <p>
 2690 <em>%C(&#8230;)</em>: color specification, as described under Values in the
 2691   "CONFIGURATION FILE" section of <a href="git-config.html">git-config(1)</a>.
 2692   By default, colors are shown only when enabled for log output (by
 2693   <code>color.diff</code>, <code>color.ui</code>, or <code>--color</code>, and respecting the <code>auto</code>
 2694   settings of the former if we are going to a terminal). <code>%C(auto,...)</code>
 2695   is accepted as a historical synonym for the default (e.g.,
 2696   <code>%C(auto,red)</code>). Specifying <code>%C(always,...) will show the colors
 2697   even when color is not otherwise enabled (though consider
 2698   just using `--color=always</code> to enable color for the whole output,
 2699   including this format and anything else git might color).  <code>auto</code>
 2700   alone (i.e. <code>%C(auto)</code>) will turn on auto coloring on the next
 2701   placeholders until the color is switched again.
 2702 </p>
 2703 </li>
 2704 <li>
 2705 <p>
 2706 <em>%m</em>: left (<code>&lt;</code>), right (<code>&gt;</code>) or boundary (<code>-</code>) mark
 2707 </p>
 2708 </li>
 2709 <li>
 2710 <p>
 2711 <em>%n</em>: newline
 2712 </p>
 2713 </li>
 2714 <li>
 2715 <p>
 2716 <em>%%</em>: a raw <em>%</em>
 2717 </p>
 2718 </li>
 2719 <li>
 2720 <p>
 2721 <em>%x00</em>: print a byte from a hex code
 2722 </p>
 2723 </li>
 2724 <li>
 2725 <p>
 2726 <em>%w([&lt;w&gt;[,&lt;i1&gt;[,&lt;i2&gt;]]])</em>: switch line wrapping, like the -w option of
 2727   <a href="git-shortlog.html">git-shortlog(1)</a>.
 2728 </p>
 2729 </li>
 2730 <li>
 2731 <p>
 2732 <em>%&lt;(&lt;N&gt;[,trunc|ltrunc|mtrunc])</em>: make the next placeholder take at
 2733   least N columns, padding spaces on the right if necessary.
 2734   Optionally truncate at the beginning (ltrunc), the middle (mtrunc)
 2735   or the end (trunc) if the output is longer than N columns.
 2736   Note that truncating only works correctly with N &gt;= 2.
 2737 </p>
 2738 </li>
 2739 <li>
 2740 <p>
 2741 <em>%&lt;|(&lt;N&gt;)</em>: make the next placeholder take at least until Nth
 2742   columns, padding spaces on the right if necessary
 2743 </p>
 2744 </li>
 2745 <li>
 2746 <p>
 2747 <em>%&gt;(&lt;N&gt;)</em>, <em>%&gt;|(&lt;N&gt;)</em>: similar to <em>%&lt;(&lt;N&gt;)</em>, <em>%&lt;|(&lt;N&gt;)</em>
 2748   respectively, but padding spaces on the left
 2749 </p>
 2750 </li>
 2751 <li>
 2752 <p>
 2753 <em>%&gt;&gt;(&lt;N&gt;)</em>, <em>%&gt;&gt;|(&lt;N&gt;)</em>: similar to <em>%&gt;(&lt;N&gt;)</em>, <em>%&gt;|(&lt;N&gt;)</em>
 2754   respectively, except that if the next placeholder takes more spaces
 2755   than given and there are spaces on its left, use those spaces
 2756 </p>
 2757 </li>
 2758 <li>
 2759 <p>
 2760 <em>%&gt;&lt;(&lt;N&gt;)</em>, <em>%&gt;&lt;|(&lt;N&gt;)</em>: similar to <em>%&lt;(&lt;N&gt;)</em>, <em>%&lt;|(&lt;N&gt;)</em>
 2761   respectively, but padding both sides (i.e. the text is centered)
 2762 </p>
 2763 </li>
 2764 <li>
 2765 <p>
 2766 %(trailers[:options]): display the trailers of the body as interpreted
 2767   by <a href="git-interpret-trailers.html">git-interpret-trailers(1)</a>. The <code>trailers</code> string may be
 2768   followed by a colon and zero or more comma-separated options. If the
 2769   <code>only</code> option is given, omit non-trailer lines from the trailer block.
 2770   If the <code>unfold</code> option is given, behave as if interpret-trailer&#8217;s
 2771   <code>--unfold</code> option was given.  E.g., <code>%(trailers:only,unfold)</code> to do
 2772   both.
 2773 </p>
 2774 </li>
 2775 </ul></div>
 2776 </li>
 2777 </ul></div>
 2778 <div class="admonitionblock">
 2779 <table><tr>
 2780 <td class="icon">
 2781 <div class="title">Note</div>
 2782 </td>
 2783 <td class="content">Some placeholders may depend on other options given to the
 2784 revision traversal engine. For example, the <code>%g*</code> reflog options will
 2785 insert an empty string unless we are traversing reflog entries (e.g., by
 2786 <code>git log -g</code>). The <code>%d</code> and <code>%D</code> placeholders will use the "short"
 2787 decoration format if <code>--decorate</code> was not already provided on the command
 2788 line.</td>
 2789 </tr></table>
 2790 </div>
 2791 <div class="paragraph"><p>If you add a <code>+</code> (plus sign) after <em>%</em> of a placeholder, a line-feed
 2792 is inserted immediately before the expansion if and only if the
 2793 placeholder expands to a non-empty string.</p></div>
 2794 <div class="paragraph"><p>If you add a <code>-</code> (minus sign) after <em>%</em> of a placeholder, all consecutive
 2795 line-feeds immediately preceding the expansion are deleted if and only if the
 2796 placeholder expands to an empty string.</p></div>
 2797 <div class="paragraph"><p>If you add a ` ` (space) after <em>%</em> of a placeholder, a space
 2798 is inserted immediately before the expansion if and only if the
 2799 placeholder expands to a non-empty string.</p></div>
 2800 <div class="ulist"><ul>
 2801 <li>
 2802 <p>
 2803 <em>tformat:</em>
 2804 </p>
 2805 <div class="paragraph"><p>The <em>tformat:</em> format works exactly like <em>format:</em>, except that it
 2806 provides "terminator" semantics instead of "separator" semantics. In
 2807 other words, each commit has the message terminator character (usually a
 2808 newline) appended, rather than a separator placed between entries.
 2809 This means that the final entry of a single-line format will be properly
 2810 terminated with a new line, just as the "oneline" format does.
 2811 For example:</p></div>
 2812 <div class="listingblock">
 2813 <div class="content">
 2814 <pre><code>$ git log -2 --pretty=format:%h 4da45bef \
 2815   | perl -pe '$_ .= " -- NO NEWLINE\n" unless /\n/'
 2816 4da45be
 2817 7134973 -- NO NEWLINE
 2818 
 2819 $ git log -2 --pretty=tformat:%h 4da45bef \
 2820   | perl -pe '$_ .= " -- NO NEWLINE\n" unless /\n/'
 2821 4da45be
 2822 7134973</code></pre>
 2823 </div></div>
 2824 <div class="paragraph"><p>In addition, any unrecognized string that has a <code>%</code> in it is interpreted
 2825 as if it has <code>tformat:</code> in front of it.  For example, these two are
 2826 equivalent:</p></div>
 2827 <div class="listingblock">
 2828 <div class="content">
 2829 <pre><code>$ git log -2 --pretty=tformat:%h 4da45bef
 2830 $ git log -2 --pretty=%h 4da45bef</code></pre>
 2831 </div></div>
 2832 </li>
 2833 </ul></div>
 2834 </div>
 2835 </div>
 2836 <div class="sect1">
 2837 <h2 id="_common_diff_options">COMMON DIFF OPTIONS</h2>
 2838 <div class="sectionbody">
 2839 <div class="dlist"><dl>
 2840 <dt class="hdlist1">
 2841 -p
 2842 </dt>
 2843 <dt class="hdlist1">
 2844 -u
 2845 </dt>
 2846 <dt class="hdlist1">
 2847 --patch
 2848 </dt>
 2849 <dd>
 2850 <p>
 2851         Generate patch (see section on generating patches).
 2852 </p>
 2853 </dd>
 2854 <dt class="hdlist1">
 2855 -s
 2856 </dt>
 2857 <dt class="hdlist1">
 2858 --no-patch
 2859 </dt>
 2860 <dd>
 2861 <p>
 2862         Suppress diff output. Useful for commands like <code>git show</code> that
 2863         show the patch by default, or to cancel the effect of <code>--patch</code>.
 2864 </p>
 2865 </dd>
 2866 <dt class="hdlist1">
 2867 -U&lt;n&gt;
 2868 </dt>
 2869 <dt class="hdlist1">
 2870 --unified=&lt;n&gt;
 2871 </dt>
 2872 <dd>
 2873 <p>
 2874         Generate diffs with &lt;n&gt; lines of context instead of
 2875         the usual three.
 2876         Implies <code>-p</code>.
 2877 </p>
 2878 </dd>
 2879 <dt class="hdlist1">
 2880 --raw
 2881 </dt>
 2882 <dd>
 2883 <p>
 2884         For each commit, show a summary of changes using the raw diff
 2885         format. See the "RAW OUTPUT FORMAT" section of
 2886         <a href="git-diff.html">git-diff(1)</a>. This is different from showing the log
 2887         itself in raw format, which you can achieve with
 2888         <code>--format=raw</code>.
 2889 </p>
 2890 </dd>
 2891 <dt class="hdlist1">
 2892 --patch-with-raw
 2893 </dt>
 2894 <dd>
 2895 <p>
 2896         Synonym for <code>-p --raw</code>.
 2897 </p>
 2898 </dd>
 2899 <dt class="hdlist1">
 2900 --indent-heuristic
 2901 </dt>
 2902 <dd>
 2903 <p>
 2904         Enable the heuristic that shifts diff hunk boundaries to make patches
 2905         easier to read. This is the default.
 2906 </p>
 2907 </dd>
 2908 <dt class="hdlist1">
 2909 --no-indent-heuristic
 2910 </dt>
 2911 <dd>
 2912 <p>
 2913         Disable the indent heuristic.
 2914 </p>
 2915 </dd>
 2916 <dt class="hdlist1">
 2917 --minimal
 2918 </dt>
 2919 <dd>
 2920 <p>
 2921         Spend extra time to make sure the smallest possible
 2922         diff is produced.
 2923 </p>
 2924 </dd>
 2925 <dt class="hdlist1">
 2926 --patience
 2927 </dt>
 2928 <dd>
 2929 <p>
 2930         Generate a diff using the "patience diff" algorithm.
 2931 </p>
 2932 </dd>
 2933 <dt class="hdlist1">
 2934 --histogram
 2935 </dt>
 2936 <dd>
 2937 <p>
 2938         Generate a diff using the "histogram diff" algorithm.
 2939 </p>
 2940 </dd>
 2941 <dt class="hdlist1">
 2942 --anchored=&lt;text&gt;
 2943 </dt>
 2944 <dd>
 2945 <p>
 2946         Generate a diff using the "anchored diff" algorithm.
 2947 </p>
 2948 <div class="paragraph"><p>This option may be specified more than once.</p></div>
 2949 <div class="paragraph"><p>If a line exists in both the source and destination, exists only once,
 2950 and starts with this text, this algorithm attempts to prevent it from
 2951 appearing as a deletion or addition in the output. It uses the "patience
 2952 diff" algorithm internally.</p></div>
 2953 </dd>
 2954 <dt class="hdlist1">
 2955 --diff-algorithm={patience|minimal|histogram|myers}
 2956 </dt>
 2957 <dd>
 2958 <p>
 2959         Choose a diff algorithm. The variants are as follows:
 2960 </p>
 2961 <div class="openblock">
 2962 <div class="content">
 2963 <div class="dlist"><dl>
 2964 <dt class="hdlist1">
 2965 <code>default</code>, <code>myers</code>
 2966 </dt>
 2967 <dd>
 2968 <p>
 2969         The basic greedy diff algorithm. Currently, this is the default.
 2970 </p>
 2971 </dd>
 2972 <dt class="hdlist1">
 2973 <code>minimal</code>
 2974 </dt>
 2975 <dd>
 2976 <p>
 2977         Spend extra time to make sure the smallest possible diff is
 2978         produced.
 2979 </p>
 2980 </dd>
 2981 <dt class="hdlist1">
 2982 <code>patience</code>
 2983 </dt>
 2984 <dd>
 2985 <p>
 2986         Use "patience diff" algorithm when generating patches.
 2987 </p>
 2988 </dd>
 2989 <dt class="hdlist1">
 2990 <code>histogram</code>
 2991 </dt>
 2992 <dd>
 2993 <p>
 2994         This algorithm extends the patience algorithm to "support
 2995         low-occurrence common elements".
 2996 </p>
 2997 </dd>
 2998 </dl></div>
 2999 </div></div>
 3000 <div class="paragraph"><p>For instance, if you configured the <code>diff.algorithm</code> variable to a
 3001 non-default value and want to use the default one, then you
 3002 have to use <code>--diff-algorithm=default</code> option.</p></div>
 3003 </dd>
 3004 <dt class="hdlist1">
 3005 --stat[=&lt;width&gt;[,&lt;name-width&gt;[,&lt;count&gt;]]]
 3006 </dt>
 3007 <dd>
 3008 <p>
 3009         Generate a diffstat. By default, as much space as necessary
 3010         will be used for the filename part, and the rest for the graph
 3011         part. Maximum width defaults to terminal width, or 80 columns
 3012         if not connected to a terminal, and can be overridden by
 3013         <code>&lt;width&gt;</code>. The width of the filename part can be limited by
 3014         giving another width <code>&lt;name-width&gt;</code> after a comma. The width
 3015         of the graph part can be limited by using
 3016         <code>--stat-graph-width=&lt;width&gt;</code> (affects all commands generating
 3017         a stat graph) or by setting <code>diff.statGraphWidth=&lt;width&gt;</code>
 3018         (does not affect <code>git format-patch</code>).
 3019         By giving a third parameter <code>&lt;count&gt;</code>, you can limit the
 3020         output to the first <code>&lt;count&gt;</code> lines, followed by <code>...</code> if
 3021         there are more.
 3022 </p>
 3023 <div class="paragraph"><p>These parameters can also be set individually with <code>--stat-width=&lt;width&gt;</code>,
 3024 <code>--stat-name-width=&lt;name-width&gt;</code> and <code>--stat-count=&lt;count&gt;</code>.</p></div>
 3025 </dd>
 3026 <dt class="hdlist1">
 3027 --compact-summary
 3028 </dt>
 3029 <dd>
 3030 <p>
 3031         Output a condensed summary of extended header information such
 3032         as file creations or deletions ("new" or "gone", optionally "+l"
 3033         if it&#8217;s a symlink) and mode changes ("+x" or "-x" for adding
 3034         or removing executable bit respectively) in diffstat. The
 3035         information is put between the filename part and the graph
 3036         part. Implies <code>--stat</code>.
 3037 </p>
 3038 </dd>
 3039 <dt class="hdlist1">
 3040 --numstat
 3041 </dt>
 3042 <dd>
 3043 <p>
 3044         Similar to <code>--stat</code>, but shows number of added and
 3045         deleted lines in decimal notation and pathname without
 3046         abbreviation, to make it more machine friendly.  For
 3047         binary files, outputs two <code>-</code> instead of saying
 3048         <code>0 0</code>.
 3049 </p>
 3050 </dd>
 3051 <dt class="hdlist1">
 3052 --shortstat
 3053 </dt>
 3054 <dd>
 3055 <p>
 3056         Output only the last line of the <code>--stat</code> format containing total
 3057         number of modified files, as well as number of added and deleted
 3058         lines.
 3059 </p>
 3060 </dd>
 3061 <dt class="hdlist1">
 3062 --dirstat[=&lt;param1,param2,&#8230;&gt;]
 3063 </dt>
 3064 <dd>
 3065 <p>
 3066         Output the distribution of relative amount of changes for each
 3067         sub-directory. The behavior of <code>--dirstat</code> can be customized by
 3068         passing it a comma separated list of parameters.
 3069         The defaults are controlled by the <code>diff.dirstat</code> configuration
 3070         variable (see <a href="git-config.html">git-config(1)</a>).
 3071         The following parameters are available:
 3072 </p>
 3073 <div class="openblock">
 3074 <div class="content">
 3075 <div class="dlist"><dl>
 3076 <dt class="hdlist1">
 3077 <code>changes</code>
 3078 </dt>
 3079 <dd>
 3080 <p>
 3081         Compute the dirstat numbers by counting the lines that have been
 3082         removed from the source, or added to the destination. This ignores
 3083         the amount of pure code movements within a file.  In other words,
 3084         rearranging lines in a file is not counted as much as other changes.
 3085         This is the default behavior when no parameter is given.
 3086 </p>
 3087 </dd>
 3088 <dt class="hdlist1">
 3089 <code>lines</code>
 3090 </dt>
 3091 <dd>
 3092 <p>
 3093         Compute the dirstat numbers by doing the regular line-based diff
 3094         analysis, and summing the removed/added line counts. (For binary
 3095         files, count 64-byte chunks instead, since binary files have no
 3096         natural concept of lines). This is a more expensive <code>--dirstat</code>
 3097         behavior than the <code>changes</code> behavior, but it does count rearranged
 3098         lines within a file as much as other changes. The resulting output
 3099         is consistent with what you get from the other <code>--*stat</code> options.
 3100 </p>
 3101 </dd>
 3102 <dt class="hdlist1">
 3103 <code>files</code>
 3104 </dt>
 3105 <dd>
 3106 <p>
 3107         Compute the dirstat numbers by counting the number of files changed.
 3108         Each changed file counts equally in the dirstat analysis. This is
 3109         the computationally cheapest <code>--dirstat</code> behavior, since it does
 3110         not have to look at the file contents at all.
 3111 </p>
 3112 </dd>
 3113 <dt class="hdlist1">
 3114 <code>cumulative</code>
 3115 </dt>
 3116 <dd>
 3117 <p>
 3118         Count changes in a child directory for the parent directory as well.
 3119         Note that when using <code>cumulative</code>, the sum of the percentages
 3120         reported may exceed 100%. The default (non-cumulative) behavior can
 3121         be specified with the <code>noncumulative</code> parameter.
 3122 </p>
 3123 </dd>
 3124 <dt class="hdlist1">
 3125 &lt;limit&gt;
 3126 </dt>
 3127 <dd>
 3128 <p>
 3129         An integer parameter specifies a cut-off percent (3% by default).
 3130         Directories contributing less than this percentage of the changes
 3131         are not shown in the output.
 3132 </p>
 3133 </dd>
 3134 </dl></div>
 3135 </div></div>
 3136 <div class="paragraph"><p>Example: The following will count changed files, while ignoring
 3137 directories with less than 10% of the total amount of changed files,
 3138 and accumulating child directory counts in the parent directories:
 3139 <code>--dirstat=files,10,cumulative</code>.</p></div>
 3140 </dd>
 3141 <dt class="hdlist1">
 3142 --summary
 3143 </dt>
 3144 <dd>
 3145 <p>
 3146         Output a condensed summary of extended header information
 3147         such as creations, renames and mode changes.
 3148 </p>
 3149 </dd>
 3150 <dt class="hdlist1">
 3151 --patch-with-stat
 3152 </dt>
 3153 <dd>
 3154 <p>
 3155         Synonym for <code>-p --stat</code>.
 3156 </p>
 3157 </dd>
 3158 <dt class="hdlist1">
 3159 -z
 3160 </dt>
 3161 <dd>
 3162 <p>
 3163         Separate the commits with NULs instead of with new newlines.
 3164 </p>
 3165 <div class="paragraph"><p>Also, when <code>--raw</code> or <code>--numstat</code> has been given, do not munge
 3166 pathnames and use NULs as output field terminators.</p></div>
 3167 <div class="paragraph"><p>Without this option, pathnames with "unusual" characters are quoted as
 3168 explained for the configuration variable <code>core.quotePath</code> (see
 3169 <a href="git-config.html">git-config(1)</a>).</p></div>
 3170 </dd>
 3171 <dt class="hdlist1">
 3172 --name-only
 3173 </dt>
 3174 <dd>
 3175 <p>
 3176         Show only names of changed files.
 3177 </p>
 3178 </dd>
 3179 <dt class="hdlist1">
 3180 --name-status
 3181 </dt>
 3182 <dd>
 3183 <p>
 3184         Show only names and status of changed files. See the description
 3185         of the <code>--diff-filter</code> option on what the status letters mean.
 3186 </p>
 3187 </dd>
 3188 <dt class="hdlist1">
 3189 --submodule[=&lt;format&gt;]
 3190 </dt>
 3191 <dd>
 3192 <p>
 3193         Specify how differences in submodules are shown.  When specifying
 3194         <code>--submodule=short</code> the <em>short</em> format is used.  This format just
 3195         shows the names of the commits at the beginning and end of the range.
 3196         When <code>--submodule</code> or <code>--submodule=log</code> is specified, the <em>log</em>
 3197         format is used.  This format lists the commits in the range like
 3198         <a href="git-submodule.html">git-submodule(1)</a> <code>summary</code> does.  When <code>--submodule=diff</code>
 3199         is specified, the <em>diff</em> format is used.  This format shows an
 3200         inline diff of the changes in the submodule contents between the
 3201         commit range.  Defaults to <code>diff.submodule</code> or the <em>short</em> format
 3202         if the config option is unset.
 3203 </p>
 3204 </dd>
 3205 <dt class="hdlist1">
 3206 --color[=&lt;when&gt;]
 3207 </dt>
 3208 <dd>
 3209 <p>
 3210         Show colored diff.
 3211         <code>--color</code> (i.e. without <em>=&lt;when&gt;</em>) is the same as <code>--color=always</code>.
 3212         <em>&lt;when&gt;</em> can be one of <code>always</code>, <code>never</code>, or <code>auto</code>.
 3213 </p>
 3214 </dd>
 3215 <dt class="hdlist1">
 3216 --no-color
 3217 </dt>
 3218 <dd>
 3219 <p>
 3220         Turn off colored diff.
 3221         It is the same as <code>--color=never</code>.
 3222 </p>
 3223 </dd>
 3224 <dt class="hdlist1">
 3225 --color-moved[=&lt;mode&gt;]
 3226 </dt>
 3227 <dd>
 3228 <p>
 3229         Moved lines of code are colored differently.
 3230         The &lt;mode&gt; defaults to <em>no</em> if the option is not given
 3231         and to <em>zebra</em> if the option with no mode is given.
 3232         The mode must be one of:
 3233 </p>
 3234 <div class="openblock">
 3235 <div class="content">
 3236 <div class="dlist"><dl>
 3237 <dt class="hdlist1">
 3238 no
 3239 </dt>
 3240 <dd>
 3241 <p>
 3242         Moved lines are not highlighted.
 3243 </p>
 3244 </dd>
 3245 <dt class="hdlist1">
 3246 default
 3247 </dt>
 3248 <dd>
 3249 <p>
 3250         Is a synonym for <code>zebra</code>. This may change to a more sensible mode
 3251         in the future.
 3252 </p>
 3253 </dd>
 3254 <dt class="hdlist1">
 3255 plain
 3256 </dt>
 3257 <dd>
 3258 <p>
 3259         Any line that is added in one location and was removed
 3260         in another location will be colored with <em>color.diff.newMoved</em>.
 3261         Similarly <em>color.diff.oldMoved</em> will be used for removed lines
 3262         that are added somewhere else in the diff. This mode picks up any
 3263         moved line, but it is not very useful in a review to determine
 3264         if a block of code was moved without permutation.
 3265 </p>
 3266 </dd>
 3267 <dt class="hdlist1">
 3268 blocks
 3269 </dt>
 3270 <dd>
 3271 <p>
 3272         Blocks of moved text of at least 20 alphanumeric characters
 3273         are detected greedily. The detected blocks are
 3274         painted using either the <em>color.diff.{old,new}Moved</em> color.
 3275         Adjacent blocks cannot be told apart.
 3276 </p>
 3277 </dd>
 3278 <dt class="hdlist1">
 3279 zebra
 3280 </dt>
 3281 <dd>
 3282 <p>
 3283         Blocks of moved text are detected as in <em>blocks</em> mode. The blocks
 3284         are painted using either the <em>color.diff.{old,new}Moved</em> color or
 3285         <em>color.diff.{old,new}MovedAlternative</em>. The change between
 3286         the two colors indicates that a new block was detected.
 3287 </p>
 3288 </dd>
 3289 <dt class="hdlist1">
 3290 dimmed-zebra
 3291 </dt>
 3292 <dd>
 3293 <p>
 3294         Similar to <em>zebra</em>, but additional dimming of uninteresting parts
 3295         of moved code is performed. The bordering lines of two adjacent
 3296         blocks are considered interesting, the rest is uninteresting.
 3297         <code>dimmed_zebra</code> is a deprecated synonym.
 3298 </p>
 3299 </dd>
 3300 </dl></div>
 3301 </div></div>
 3302 </dd>
 3303 <dt class="hdlist1">
 3304 --color-moved-ws=&lt;modes&gt;
 3305 </dt>
 3306 <dd>
 3307 <p>
 3308         This configures how white spaces are ignored when performing the
 3309         move detection for <code>--color-moved</code>.
 3310         These modes can be given as a comma separated list:
 3311 </p>
 3312 <div class="openblock">
 3313 <div class="content">
 3314 <div class="dlist"><dl>
 3315 <dt class="hdlist1">
 3316 ignore-space-at-eol
 3317 </dt>
 3318 <dd>
 3319 <p>
 3320         Ignore changes in whitespace at EOL.
 3321 </p>
 3322 </dd>
 3323 <dt class="hdlist1">
 3324 ignore-space-change
 3325 </dt>
 3326 <dd>
 3327 <p>
 3328         Ignore changes in amount of whitespace.  This ignores whitespace
 3329         at line end, and considers all other sequences of one or
 3330         more whitespace characters to be equivalent.
 3331 </p>
 3332 </dd>
 3333 <dt class="hdlist1">
 3334 ignore-all-space
 3335 </dt>
 3336 <dd>
 3337 <p>
 3338         Ignore whitespace when comparing lines. This ignores differences
 3339         even if one line has whitespace where the other line has none.
 3340 </p>
 3341 </dd>
 3342 <dt class="hdlist1">
 3343 allow-indentation-change
 3344 </dt>
 3345 <dd>
 3346 <p>
 3347         Initially ignore any white spaces in the move detection, then
 3348         group the moved code blocks only into a block if the change in
 3349         whitespace is the same per line. This is incompatible with the
 3350         other modes.
 3351 </p>
 3352 </dd>
 3353 </dl></div>
 3354 </div></div>
 3355 </dd>
 3356 <dt class="hdlist1">
 3357 --word-diff[=&lt;mode&gt;]
 3358 </dt>
 3359 <dd>
 3360 <p>
 3361         Show a word diff, using the &lt;mode&gt; to delimit changed words.
 3362         By default, words are delimited by whitespace; see
 3363         <code>--word-diff-regex</code> below.  The &lt;mode&gt; defaults to <em>plain</em>, and
 3364         must be one of:
 3365 </p>
 3366 <div class="openblock">
 3367 <div class="content">
 3368 <div class="dlist"><dl>
 3369 <dt class="hdlist1">
 3370 color
 3371 </dt>
 3372 <dd>
 3373 <p>
 3374         Highlight changed words using only colors.  Implies <code>--color</code>.
 3375 </p>
 3376 </dd>
 3377 <dt class="hdlist1">
 3378 plain
 3379 </dt>
 3380 <dd>
 3381 <p>
 3382         Show words as <code>[-removed-]</code> and <code>{+added+}</code>.  Makes no
 3383         attempts to escape the delimiters if they appear in the input,
 3384         so the output may be ambiguous.
 3385 </p>
 3386 </dd>
 3387 <dt class="hdlist1">
 3388 porcelain
 3389 </dt>
 3390 <dd>
 3391 <p>
 3392         Use a special line-based format intended for script
 3393         consumption.  Added/removed/unchanged runs are printed in the
 3394         usual unified diff format, starting with a <code>+</code>/<code>-</code>/` `
 3395         character at the beginning of the line and extending to the
 3396         end of the line.  Newlines in the input are represented by a
 3397         tilde <code>~</code> on a line of its own.
 3398 </p>
 3399 </dd>
 3400 <dt class="hdlist1">
 3401 none
 3402 </dt>
 3403 <dd>
 3404 <p>
 3405         Disable word diff again.
 3406 </p>
 3407 </dd>
 3408 </dl></div>
 3409 </div></div>
 3410 <div class="paragraph"><p>Note that despite the name of the first mode, color is used to
 3411 highlight the changed parts in all modes if enabled.</p></div>
 3412 </dd>
 3413 <dt class="hdlist1">
 3414 --word-diff-regex=&lt;regex&gt;
 3415 </dt>
 3416 <dd>
 3417 <p>
 3418         Use &lt;regex&gt; to decide what a word is, instead of considering
 3419         runs of non-whitespace to be a word.  Also implies
 3420         <code>--word-diff</code> unless it was already enabled.
 3421 </p>
 3422 <div class="paragraph"><p>Every non-overlapping match of the
 3423 &lt;regex&gt; is considered a word.  Anything between these matches is
 3424 considered whitespace and ignored(!) for the purposes of finding
 3425 differences.  You may want to append <code>|[^[:space:]]</code> to your regular
 3426 expression to make sure that it matches all non-whitespace characters.
 3427 A match that contains a newline is silently truncated(!) at the
 3428 newline.</p></div>
 3429 <div class="paragraph"><p>For example, <code>--word-diff-regex=.</code> will treat each character as a word
 3430 and, correspondingly, show differences character by character.</p></div>
 3431 <div class="paragraph"><p>The regex can also be set via a diff driver or configuration option, see
 3432 <a href="gitattributes.html">gitattributes(5)</a> or <a href="git-config.html">git-config(1)</a>.  Giving it explicitly
 3433 overrides any diff driver or configuration setting.  Diff drivers
 3434 override configuration settings.</p></div>
 3435 </dd>
 3436 <dt class="hdlist1">
 3437 --color-words[=&lt;regex&gt;]
 3438 </dt>
 3439 <dd>
 3440 <p>
 3441         Equivalent to <code>--word-diff=color</code> plus (if a regex was
 3442         specified) <code>--word-diff-regex=&lt;regex&gt;</code>.
 3443 </p>
 3444 </dd>
 3445 <dt class="hdlist1">
 3446 --no-renames
 3447 </dt>
 3448 <dd>
 3449 <p>
 3450         Turn off rename detection, even when the configuration
 3451         file gives the default to do so.
 3452 </p>
 3453 </dd>
 3454 <dt class="hdlist1">
 3455 --check
 3456 </dt>
 3457 <dd>
 3458 <p>
 3459         Warn if changes introduce conflict markers or whitespace errors.
 3460         What are considered whitespace errors is controlled by <code>core.whitespace</code>
 3461         configuration.  By default, trailing whitespaces (including
 3462         lines that consist solely of whitespaces) and a space character
 3463         that is immediately followed by a tab character inside the
 3464         initial indent of the line are considered whitespace errors.
 3465         Exits with non-zero status if problems are found. Not compatible
 3466         with --exit-code.
 3467 </p>
 3468 </dd>
 3469 <dt class="hdlist1">
 3470 --ws-error-highlight=&lt;kind&gt;
 3471 </dt>
 3472 <dd>
 3473 <p>
 3474         Highlight whitespace errors in the <code>context</code>, <code>old</code> or <code>new</code>
 3475         lines of the diff.  Multiple values are separated by comma,
 3476         <code>none</code> resets previous values, <code>default</code> reset the list to
 3477         <code>new</code> and <code>all</code> is a shorthand for <code>old,new,context</code>.  When
 3478         this option is not given, and the configuration variable
 3479         <code>diff.wsErrorHighlight</code> is not set, only whitespace errors in
 3480         <code>new</code> lines are highlighted. The whitespace errors are colored
 3481         with <code>color.diff.whitespace</code>.
 3482 </p>
 3483 </dd>
 3484 <dt class="hdlist1">
 3485 --full-index
 3486 </dt>
 3487 <dd>
 3488 <p>
 3489         Instead of the first handful of characters, show the full
 3490         pre- and post-image blob object names on the "index"
 3491         line when generating patch format output.
 3492 </p>
 3493 </dd>
 3494 <dt class="hdlist1">
 3495 --binary
 3496 </dt>
 3497 <dd>
 3498 <p>
 3499         In addition to <code>--full-index</code>, output a binary diff that
 3500         can be applied with <code>git-apply</code>.
 3501 </p>
 3502 </dd>
 3503 <dt class="hdlist1">
 3504 --abbrev[=&lt;n&gt;]
 3505 </dt>
 3506 <dd>
 3507 <p>
 3508         Instead of showing the full 40-byte hexadecimal object
 3509         name in diff-raw format output and diff-tree header
 3510         lines, show only a partial prefix.  This is
 3511         independent of the <code>--full-index</code> option above, which controls
 3512         the diff-patch output format.  Non default number of
 3513         digits can be specified with <code>--abbrev=&lt;n&gt;</code>.
 3514 </p>
 3515 </dd>
 3516 <dt class="hdlist1">
 3517 -B[&lt;n&gt;][/&lt;m&gt;]
 3518 </dt>
 3519 <dt class="hdlist1">
 3520 --break-rewrites[=[&lt;n&gt;][/&lt;m&gt;]]
 3521 </dt>
 3522 <dd>
 3523 <p>
 3524         Break complete rewrite changes into pairs of delete and
 3525         create. This serves two purposes:
 3526 </p>
 3527 <div class="paragraph"><p>It affects the way a change that amounts to a total rewrite of a file
 3528 not as a series of deletion and insertion mixed together with a very
 3529 few lines that happen to match textually as the context, but as a
 3530 single deletion of everything old followed by a single insertion of
 3531 everything new, and the number <code>m</code> controls this aspect of the -B
 3532 option (defaults to 60%). <code>-B/70%</code> specifies that less than 30% of the
 3533 original should remain in the result for Git to consider it a total
 3534 rewrite (i.e. otherwise the resulting patch will be a series of
 3535 deletion and insertion mixed together with context lines).</p></div>
 3536 <div class="paragraph"><p>When used with -M, a totally-rewritten file is also considered as the
 3537 source of a rename (usually -M only considers a file that disappeared
 3538 as the source of a rename), and the number <code>n</code> controls this aspect of
 3539 the -B option (defaults to 50%). <code>-B20%</code> specifies that a change with
 3540 addition and deletion compared to 20% or more of the file&#8217;s size are
 3541 eligible for being picked up as a possible source of a rename to
 3542 another file.</p></div>
 3543 </dd>
 3544 <dt class="hdlist1">
 3545 -M[&lt;n&gt;]
 3546 </dt>
 3547 <dt class="hdlist1">
 3548 --find-renames[=&lt;n&gt;]
 3549 </dt>
 3550 <dd>
 3551 <p>
 3552         If generating diffs, detect and report renames for each commit.
 3553         For following files across renames while traversing history, see
 3554         <code>--follow</code>.
 3555         If <code>n</code> is specified, it is a threshold on the similarity
 3556         index (i.e. amount of addition/deletions compared to the
 3557         file&#8217;s size). For example, <code>-M90%</code> means Git should consider a
 3558         delete/add pair to be a rename if more than 90% of the file
 3559         hasn&#8217;t changed.  Without a <code>%</code> sign, the number is to be read as
 3560         a fraction, with a decimal point before it.  I.e., <code>-M5</code> becomes
 3561         0.5, and is thus the same as <code>-M50%</code>.  Similarly, <code>-M05</code> is
 3562         the same as <code>-M5%</code>.  To limit detection to exact renames, use
 3563         <code>-M100%</code>.  The default similarity index is 50%.
 3564 </p>
 3565 </dd>
 3566 <dt class="hdlist1">
 3567 -C[&lt;n&gt;]
 3568 </dt>
 3569 <dt class="hdlist1">
 3570 --find-copies[=&lt;n&gt;]
 3571 </dt>
 3572 <dd>
 3573 <p>
 3574         Detect copies as well as renames.  See also <code>--find-copies-harder</code>.
 3575         If <code>n</code> is specified, it has the same meaning as for <code>-M&lt;n&gt;</code>.
 3576 </p>
 3577 </dd>
 3578 <dt class="hdlist1">
 3579 --find-copies-harder
 3580 </dt>
 3581 <dd>
 3582 <p>
 3583         For performance reasons, by default, <code>-C</code> option finds copies only
 3584         if the original file of the copy was modified in the same
 3585         changeset.  This flag makes the command
 3586         inspect unmodified files as candidates for the source of
 3587         copy.  This is a very expensive operation for large
 3588         projects, so use it with caution.  Giving more than one
 3589         <code>-C</code> option has the same effect.
 3590 </p>
 3591 </dd>
 3592 <dt class="hdlist1">
 3593 -D
 3594 </dt>
 3595 <dt class="hdlist1">
 3596 --irreversible-delete
 3597 </dt>
 3598 <dd>
 3599 <p>
 3600         Omit the preimage for deletes, i.e. print only the header but not
 3601         the diff between the preimage and <code>/dev/null</code>. The resulting patch
 3602         is not meant to be applied with <code>patch</code> or <code>git apply</code>; this is
 3603         solely for people who want to just concentrate on reviewing the
 3604         text after the change. In addition, the output obviously lacks
 3605         enough information to apply such a patch in reverse, even manually,
 3606         hence the name of the option.
 3607 </p>
 3608 <div class="paragraph"><p>When used together with <code>-B</code>, omit also the preimage in the deletion part
 3609 of a delete/create pair.</p></div>
 3610 </dd>
 3611 <dt class="hdlist1">
 3612 -l&lt;num&gt;
 3613 </dt>
 3614 <dd>
 3615 <p>
 3616         The <code>-M</code> and <code>-C</code> options require O(n^2) processing time where n
 3617         is the number of potential rename/copy targets.  This
 3618         option prevents rename/copy detection from running if
 3619         the number of rename/copy targets exceeds the specified
 3620         number.
 3621 </p>
 3622 </dd>
 3623 <dt class="hdlist1">
 3624 --diff-filter=[(A|C|D|M|R|T|U|X|B)&#8230;[*]]
 3625 </dt>
 3626 <dd>
 3627 <p>
 3628         Select only files that are Added (<code>A</code>), Copied (<code>C</code>),
 3629         Deleted (<code>D</code>), Modified (<code>M</code>), Renamed (<code>R</code>), have their
 3630         type (i.e. regular file, symlink, submodule, &#8230;) changed (<code>T</code>),
 3631         are Unmerged (<code>U</code>), are
 3632         Unknown (<code>X</code>), or have had their pairing Broken (<code>B</code>).
 3633         Any combination of the filter characters (including none) can be used.
 3634         When <code>*</code> (All-or-none) is added to the combination, all
 3635         paths are selected if there is any file that matches
 3636         other criteria in the comparison; if there is no file
 3637         that matches other criteria, nothing is selected.
 3638 </p>
 3639 <div class="paragraph"><p>Also, these upper-case letters can be downcased to exclude.  E.g.
 3640 <code>--diff-filter=ad</code> excludes added and deleted paths.</p></div>
 3641 <div class="paragraph"><p>Note that not all diffs can feature all types. For instance, diffs
 3642 from the index to the working tree can never have Added entries
 3643 (because the set of paths included in the diff is limited by what is in
 3644 the index).  Similarly, copied and renamed entries cannot appear if
 3645 detection for those types is disabled.</p></div>
 3646 </dd>
 3647 <dt class="hdlist1">
 3648 -S&lt;string&gt;
 3649 </dt>
 3650 <dd>
 3651 <p>
 3652         Look for differences that change the number of occurrences of
 3653         the specified string (i.e. addition/deletion) in a file.
 3654         Intended for the scripter&#8217;s use.
 3655 </p>
 3656 <div class="paragraph"><p>It is useful when you&#8217;re looking for an exact block of code (like a
 3657 struct), and want to know the history of that block since it first
 3658 came into being: use the feature iteratively to feed the interesting
 3659 block in the preimage back into <code>-S</code>, and keep going until you get the
 3660 very first version of the block.</p></div>
 3661 </dd>
 3662 <dt class="hdlist1">
 3663 -G&lt;regex&gt;
 3664 </dt>
 3665 <dd>
 3666 <p>
 3667         Look for differences whose patch text contains added/removed
 3668         lines that match &lt;regex&gt;.
 3669 </p>
 3670 <div class="paragraph"><p>To illustrate the difference between <code>-S&lt;regex&gt; --pickaxe-regex</code> and
 3671 <code>-G&lt;regex&gt;</code>, consider a commit with the following diff in the same
 3672 file:</p></div>
 3673 <div class="listingblock">
 3674 <div class="content">
 3675 <pre><code>+    return !regexec(regexp, two-&gt;ptr, 1, &amp;regmatch, 0);
 3676 ...
 3677 -    hit = !regexec(regexp, mf2.ptr, 1, &amp;regmatch, 0);</code></pre>
 3678 </div></div>
 3679 <div class="paragraph"><p>While <code>git log -G"regexec\(regexp"</code> will show this commit, <code>git log
 3680 -S"regexec\(regexp" --pickaxe-regex</code> will not (because the number of
 3681 occurrences of that string did not change).</p></div>
 3682 <div class="paragraph"><p>See the <em>pickaxe</em> entry in <a href="gitdiffcore.html">gitdiffcore(7)</a> for more
 3683 information.</p></div>
 3684 </dd>
 3685 <dt class="hdlist1">
 3686 --find-object=&lt;object-id&gt;
 3687 </dt>
 3688 <dd>
 3689 <p>
 3690         Look for differences that change the number of occurrences of
 3691         the specified object. Similar to <code>-S</code>, just the argument is different
 3692         in that it doesn&#8217;t search for a specific string but for a specific
 3693         object id.
 3694 </p>
 3695 <div class="paragraph"><p>The object can be a blob or a submodule commit. It implies the <code>-t</code> option in
 3696 <code>git-log</code> to also find trees.</p></div>
 3697 </dd>
 3698 <dt class="hdlist1">
 3699 --pickaxe-all
 3700 </dt>
 3701 <dd>
 3702 <p>
 3703         When <code>-S</code> or <code>-G</code> finds a change, show all the changes in that
 3704         changeset, not just the files that contain the change
 3705         in &lt;string&gt;.
 3706 </p>
 3707 </dd>
 3708 <dt class="hdlist1">
 3709 --pickaxe-regex
 3710 </dt>
 3711 <dd>
 3712 <p>
 3713         Treat the &lt;string&gt; given to <code>-S</code> as an extended POSIX regular
 3714         expression to match.
 3715 </p>
 3716 </dd>
 3717 <dt class="hdlist1">
 3718 -O&lt;orderfile&gt;
 3719 </dt>
 3720 <dd>
 3721 <p>
 3722         Control the order in which files appear in the output.
 3723         This overrides the <code>diff.orderFile</code> configuration variable
 3724         (see <a href="git-config.html">git-config(1)</a>).  To cancel <code>diff.orderFile</code>,
 3725         use <code>-O/dev/null</code>.
 3726 </p>
 3727 <div class="paragraph"><p>The output order is determined by the order of glob patterns in
 3728 &lt;orderfile&gt;.
 3729 All files with pathnames that match the first pattern are output
 3730 first, all files with pathnames that match the second pattern (but not
 3731 the first) are output next, and so on.
 3732 All files with pathnames that do not match any pattern are output
 3733 last, as if there was an implicit match-all pattern at the end of the
 3734 file.
 3735 If multiple pathnames have the same rank (they match the same pattern
 3736 but no earlier patterns), their output order relative to each other is
 3737 the normal order.</p></div>
 3738 <div class="paragraph"><p>&lt;orderfile&gt; is parsed as follows:</p></div>
 3739 <div class="openblock">
 3740 <div class="content">
 3741 <div class="ulist"><ul>
 3742 <li>
 3743 <p>
 3744 Blank lines are ignored, so they can be used as separators for
 3745    readability.
 3746 </p>
 3747 </li>
 3748 <li>
 3749 <p>
 3750 Lines starting with a hash ("<code>#</code>") are ignored, so they can be used
 3751    for comments.  Add a backslash ("<code>\</code>") to the beginning of the
 3752    pattern if it starts with a hash.
 3753 </p>
 3754 </li>
 3755 <li>
 3756 <p>
 3757 Each other line contains a single pattern.
 3758 </p>
 3759 </li>
 3760 </ul></div>
 3761 </div></div>
 3762 <div class="paragraph"><p>Patterns have the same syntax and semantics as patterns used for
 3763 fnmatch(3) without the FNM_PATHNAME flag, except a pathname also
 3764 matches a pattern if removing any number of the final pathname
 3765 components matches the pattern.  For example, the pattern "<code>foo*bar</code>"
 3766 matches "<code>fooasdfbar</code>" and "<code>foo/bar/baz/asdf</code>" but not "<code>foobarx</code>".</p></div>
 3767 </dd>
 3768 <dt class="hdlist1">
 3769 -R
 3770 </dt>
 3771 <dd>
 3772 <p>
 3773         Swap two inputs; that is, show differences from index or
 3774         on-disk file to tree contents.
 3775 </p>
 3776 </dd>
 3777 <dt class="hdlist1">
 3778 --relative[=&lt;path&gt;]
 3779 </dt>
 3780 <dd>
 3781 <p>
 3782         When run from a subdirectory of the project, it can be
 3783         told to exclude changes outside the directory and show
 3784         pathnames relative to it with this option.  When you are
 3785         not in a subdirectory (e.g. in a bare repository), you
 3786         can name which subdirectory to make the output relative
 3787         to by giving a &lt;path&gt; as an argument.
 3788 </p>
 3789 </dd>
 3790 <dt class="hdlist1">
 3791 -a
 3792 </dt>
 3793 <dt class="hdlist1">
 3794 --text
 3795 </dt>
 3796 <dd>
 3797 <p>
 3798         Treat all files as text.
 3799 </p>
 3800 </dd>
 3801 <dt class="hdlist1">
 3802 --ignore-cr-at-eol
 3803 </dt>
 3804 <dd>
 3805 <p>
 3806         Ignore carriage-return at the end of line when doing a comparison.
 3807 </p>
 3808 </dd>
 3809 <dt class="hdlist1">
 3810 --ignore-space-at-eol
 3811 </dt>
 3812 <dd>
 3813 <p>
 3814         Ignore changes in whitespace at EOL.
 3815 </p>
 3816 </dd>
 3817 <dt class="hdlist1">
 3818 -b
 3819 </dt>
 3820 <dt class="hdlist1">
 3821 --ignore-space-change
 3822 </dt>
 3823 <dd>
 3824 <p>
 3825         Ignore changes in amount of whitespace.  This ignores whitespace
 3826         at line end, and considers all other sequences of one or
 3827         more whitespace characters to be equivalent.
 3828 </p>
 3829 </dd>
 3830 <dt class="hdlist1">
 3831 -w
 3832 </dt>
 3833 <dt class="hdlist1">
 3834 --ignore-all-space
 3835 </dt>
 3836 <dd>
 3837 <p>
 3838         Ignore whitespace when comparing lines.  This ignores
 3839         differences even if one line has whitespace where the other
 3840         line has none.
 3841 </p>
 3842 </dd>
 3843 <dt class="hdlist1">
 3844 --ignore-blank-lines
 3845 </dt>
 3846 <dd>
 3847 <p>
 3848         Ignore changes whose lines are all blank.
 3849 </p>
 3850 </dd>
 3851 <dt class="hdlist1">
 3852 --inter-hunk-context=&lt;lines&gt;
 3853 </dt>
 3854 <dd>
 3855 <p>
 3856         Show the context between diff hunks, up to the specified number
 3857         of lines, thereby fusing hunks that are close to each other.
 3858         Defaults to <code>diff.interHunkContext</code> or 0 if the config option
 3859         is unset.
 3860 </p>
 3861 </dd>
 3862 <dt class="hdlist1">
 3863 -W
 3864 </dt>
 3865 <dt class="hdlist1">
 3866 --function-context
 3867 </dt>
 3868 <dd>
 3869 <p>
 3870         Show whole surrounding functions of changes.
 3871 </p>
 3872 </dd>
 3873 <dt class="hdlist1">
 3874 --ext-diff
 3875 </dt>
 3876 <dd>
 3877 <p>
 3878         Allow an external diff helper to be executed. If you set an
 3879         external diff driver with <a href="gitattributes.html">gitattributes(5)</a>, you need
 3880         to use this option with <a href="git-log.html">git-log(1)</a> and friends.
 3881 </p>
 3882 </dd>
 3883 <dt class="hdlist1">
 3884 --no-ext-diff
 3885 </dt>
 3886 <dd>
 3887 <p>
 3888         Disallow external diff drivers.
 3889 </p>
 3890 </dd>
 3891 <dt class="hdlist1">
 3892 --textconv
 3893 </dt>
 3894 <dt class="hdlist1">
 3895 --no-textconv
 3896 </dt>
 3897 <dd>
 3898 <p>
 3899         Allow (or disallow) external text conversion filters to be run
 3900         when comparing binary files. See <a href="gitattributes.html">gitattributes(5)</a> for
 3901         details. Because textconv filters are typically a one-way
 3902         conversion, the resulting diff is suitable for human
 3903         consumption, but cannot be applied. For this reason, textconv
 3904         filters are enabled by default only for <a href="git-diff.html">git-diff(1)</a> and
 3905         <a href="git-log.html">git-log(1)</a>, but not for <a href="git-format-patch.html">git-format-patch(1)</a> or
 3906         diff plumbing commands.
 3907 </p>
 3908 </dd>
 3909 <dt class="hdlist1">
 3910 --ignore-submodules[=&lt;when&gt;]
 3911 </dt>
 3912 <dd>
 3913 <p>
 3914         Ignore changes to submodules in the diff generation. &lt;when&gt; can be
 3915         either "none", "untracked", "dirty" or "all", which is the default.
 3916         Using "none" will consider the submodule modified when it either contains
 3917         untracked or modified files or its HEAD differs from the commit recorded
 3918         in the superproject and can be used to override any settings of the
 3919         <em>ignore</em> option in <a href="git-config.html">git-config(1)</a> or <a href="gitmodules.html">gitmodules(5)</a>. When
 3920         "untracked" is used submodules are not considered dirty when they only
 3921         contain untracked content (but they are still scanned for modified
 3922         content). Using "dirty" ignores all changes to the work tree of submodules,
 3923         only changes to the commits stored in the superproject are shown (this was
 3924         the behavior until 1.7.0). Using "all" hides all changes to submodules.
 3925 </p>
 3926 </dd>
 3927 <dt class="hdlist1">
 3928 --src-prefix=&lt;prefix&gt;
 3929 </dt>
 3930 <dd>
 3931 <p>
 3932         Show the given source prefix instead of "a/".
 3933 </p>
 3934 </dd>
 3935 <dt class="hdlist1">
 3936 --dst-prefix=&lt;prefix&gt;
 3937 </dt>
 3938 <dd>
 3939 <p>
 3940         Show the given destination prefix instead of "b/".
 3941 </p>
 3942 </dd>
 3943 <dt class="hdlist1">
 3944 --no-prefix
 3945 </dt>
 3946 <dd>
 3947 <p>
 3948         Do not show any source or destination prefix.
 3949 </p>
 3950 </dd>
 3951 <dt class="hdlist1">
 3952 --line-prefix=&lt;prefix&gt;
 3953 </dt>
 3954 <dd>
 3955 <p>
 3956         Prepend an additional prefix to every line of output.
 3957 </p>
 3958 </dd>
 3959 <dt class="hdlist1">
 3960 --ita-invisible-in-index
 3961 </dt>
 3962 <dd>
 3963 <p>
 3964         By default entries added by "git add -N" appear as an existing
 3965         empty file in "git diff" and a new file in "git diff --cached".
 3966         This option makes the entry appear as a new file in "git diff"
 3967         and non-existent in "git diff --cached". This option could be
 3968         reverted with <code>--ita-visible-in-index</code>. Both options are
 3969         experimental and could be removed in future.
 3970 </p>
 3971 </dd>
 3972 </dl></div>
 3973 <div class="paragraph"><p>For more detailed explanation on these common options, see also
 3974 <a href="gitdiffcore.html">gitdiffcore(7)</a>.</p></div>
 3975 </div>
 3976 </div>
 3977 <div class="sect1">
 3978 <h2 id="_generating_patches_with_p">Generating patches with -p</h2>
 3979 <div class="sectionbody">
 3980 <div class="paragraph"><p>When "git-diff-index", "git-diff-tree", or "git-diff-files" are run
 3981 with a <code>-p</code> option, "git diff" without the <code>--raw</code> option, or
 3982 "git log" with the "-p" option, they
 3983 do not produce the output described above; instead they produce a
 3984 patch file.  You can customize the creation of such patches via the
 3985 <code>GIT_EXTERNAL_DIFF</code> and the <code>GIT_DIFF_OPTS</code> environment variables.</p></div>
 3986 <div class="paragraph"><p>What the -p option produces is slightly different from the traditional
 3987 diff format:</p></div>
 3988 <div class="olist arabic"><ol class="arabic">
 3989 <li>
 3990 <p>
 3991 It is preceded with a "git diff" header that looks like this:
 3992 </p>
 3993 <div class="literalblock">
 3994 <div class="content">
 3995 <pre><code>diff --git a/file1 b/file2</code></pre>
 3996 </div></div>
 3997 <div class="paragraph"><p>The <code>a/</code> and <code>b/</code> filenames are the same unless rename/copy is
 3998 involved.  Especially, even for a creation or a deletion,
 3999 <code>/dev/null</code> is <em>not</em> used in place of the <code>a/</code> or <code>b/</code> filenames.</p></div>
 4000 <div class="paragraph"><p>When rename/copy is involved, <code>file1</code> and <code>file2</code> show the
 4001 name of the source file of the rename/copy and the name of
 4002 the file that rename/copy produces, respectively.</p></div>
 4003 </li>
 4004 <li>
 4005 <p>
 4006 It is followed by one or more extended header lines:
 4007 </p>
 4008 <div class="literalblock">
 4009 <div class="content">
 4010 <pre><code>old mode &lt;mode&gt;
 4011 new mode &lt;mode&gt;
 4012 deleted file mode &lt;mode&gt;
 4013 new file mode &lt;mode&gt;
 4014 copy from &lt;path&gt;
 4015 copy to &lt;path&gt;
 4016 rename from &lt;path&gt;
 4017 rename to &lt;path&gt;
 4018 similarity index &lt;number&gt;
 4019 dissimilarity index &lt;number&gt;
 4020 index &lt;hash&gt;..&lt;hash&gt; &lt;mode&gt;</code></pre>
 4021 </div></div>
 4022 <div class="paragraph"><p>File modes are printed as 6-digit octal numbers including the file type
 4023 and file permission bits.</p></div>
 4024 <div class="paragraph"><p>Path names in extended headers do not include the <code>a/</code> and <code>b/</code> prefixes.</p></div>
 4025 <div class="paragraph"><p>The similarity index is the percentage of unchanged lines, and
 4026 the dissimilarity index is the percentage of changed lines.  It
 4027 is a rounded down integer, followed by a percent sign.  The
 4028 similarity index value of 100% is thus reserved for two equal
 4029 files, while 100% dissimilarity means that no line from the old
 4030 file made it into the new one.</p></div>
 4031 <div class="paragraph"><p>The index line includes the SHA-1 checksum before and after the change.
 4032 The &lt;mode&gt; is included if the file mode does not change; otherwise,
 4033 separate lines indicate the old and the new mode.</p></div>
 4034 </li>
 4035 <li>
 4036 <p>
 4037 Pathnames with "unusual" characters are quoted as explained for
 4038     the configuration variable <code>core.quotePath</code> (see
 4039     <a href="git-config.html">git-config(1)</a>).
 4040 </p>
 4041 </li>
 4042 <li>
 4043 <p>
 4044 All the <code>file1</code> files in the output refer to files before the
 4045     commit, and all the <code>file2</code> files refer to files after the commit.
 4046     It is incorrect to apply each change to each file sequentially.  For
 4047     example, this patch will swap a and b:
 4048 </p>
 4049 <div class="literalblock">
 4050 <div class="content">
 4051 <pre><code>diff --git a/a b/b
 4052 rename from a
 4053 rename to b
 4054 diff --git a/b b/a
 4055 rename from b
 4056 rename to a</code></pre>
 4057 </div></div>
 4058 </li>
 4059 </ol></div>
 4060 </div>
 4061 </div>
 4062 <div class="sect1">
 4063 <h2 id="_combined_diff_format">combined diff format</h2>
 4064 <div class="sectionbody">
 4065 <div class="paragraph"><p>Any diff-generating command can take the <code>-c</code> or <code>--cc</code> option to
 4066 produce a <em>combined diff</em> when showing a merge. This is the default
 4067 format when showing merges with <a href="git-diff.html">git-diff(1)</a> or
 4068 <a href="git-show.html">git-show(1)</a>. Note also that you can give the <code>-m</code> option to any
 4069 of these commands to force generation of diffs with individual parents
 4070 of a merge.</p></div>
 4071 <div class="paragraph"><p>A <em>combined diff</em> format looks like this:</p></div>
 4072 <div class="listingblock">
 4073 <div class="content">
 4074 <pre><code>diff --combined describe.c
 4075 index fabadb8,cc95eb0..4866510
 4076 --- a/describe.c
 4077 +++ b/describe.c
 4078 @@@ -98,20 -98,12 +98,20 @@@
 4079         return (a_date &gt; b_date) ? -1 : (a_date == b_date) ? 0 : 1;
 4080   }
 4081 
 4082 - static void describe(char *arg)
 4083  -static void describe(struct commit *cmit, int last_one)
 4084 ++static void describe(char *arg, int last_one)
 4085   {
 4086  +      unsigned char sha1[20];
 4087  +      struct commit *cmit;
 4088         struct commit_list *list;
 4089         static int initialized = 0;
 4090         struct commit_name *n;
 4091 
 4092  +      if (get_sha1(arg, sha1) &lt; 0)
 4093  +              usage(describe_usage);
 4094  +      cmit = lookup_commit_reference(sha1);
 4095  +      if (!cmit)
 4096  +              usage(describe_usage);
 4097  +
 4098         if (!initialized) {
 4099                 initialized = 1;
 4100                 for_each_ref(get_name);</code></pre>
 4101 </div></div>
 4102 <div class="olist arabic"><ol class="arabic">
 4103 <li>
 4104 <p>
 4105 It is preceded with a "git diff" header, that looks like
 4106      this (when <code>-c</code> option is used):
 4107 </p>
 4108 <div class="literalblock">
 4109 <div class="content">
 4110 <pre><code>diff --combined file</code></pre>
 4111 </div></div>
 4112 <div class="paragraph"><p>or like this (when <code>--cc</code> option is used):</p></div>
 4113 <div class="literalblock">
 4114 <div class="content">
 4115 <pre><code>diff --cc file</code></pre>
 4116 </div></div>
 4117 </li>
 4118 <li>
 4119 <p>
 4120 It is followed by one or more extended header lines
 4121      (this example shows a merge with two parents):
 4122 </p>
 4123 <div class="literalblock">
 4124 <div class="content">
 4125 <pre><code>index &lt;hash&gt;,&lt;hash&gt;..&lt;hash&gt;
 4126 mode &lt;mode&gt;,&lt;mode&gt;..&lt;mode&gt;
 4127 new file mode &lt;mode&gt;
 4128 deleted file mode &lt;mode&gt;,&lt;mode&gt;</code></pre>
 4129 </div></div>
 4130 <div class="paragraph"><p>The <code>mode &lt;mode&gt;,&lt;mode&gt;..&lt;mode&gt;</code> line appears only if at least one of
 4131 the &lt;mode&gt; is different from the rest. Extended headers with
 4132 information about detected contents movement (renames and
 4133 copying detection) are designed to work with diff of two
 4134 &lt;tree-ish&gt; and are not used by combined diff format.</p></div>
 4135 </li>
 4136 <li>
 4137 <p>
 4138 It is followed by two-line from-file/to-file header
 4139 </p>
 4140 <div class="literalblock">
 4141 <div class="content">
 4142 <pre><code>--- a/file
 4143 +++ b/file</code></pre>
 4144 </div></div>
 4145 <div class="paragraph"><p>Similar to two-line header for traditional <em>unified</em> diff
 4146 format, <code>/dev/null</code> is used to signal created or deleted
 4147 files.</p></div>
 4148 </li>
 4149 <li>
 4150 <p>
 4151 Chunk header format is modified to prevent people from
 4152      accidentally feeding it to <code>patch -p1</code>. Combined diff format
 4153      was created for review of merge commit changes, and was not
 4154      meant for apply. The change is similar to the change in the
 4155      extended <em>index</em> header:
 4156 </p>
 4157 <div class="literalblock">
 4158 <div class="content">
 4159 <pre><code>@@@ &lt;from-file-range&gt; &lt;from-file-range&gt; &lt;to-file-range&gt; @@@</code></pre>
 4160 </div></div>
 4161 <div class="paragraph"><p>There are (number of parents + 1) <code>@</code> characters in the chunk
 4162 header for combined diff format.</p></div>
 4163 </li>
 4164 </ol></div>
 4165 <div class="paragraph"><p>Unlike the traditional <em>unified</em> diff format, which shows two
 4166 files A and B with a single column that has <code>-</code> (minus&#8201;&#8212;&#8201;appears in A but removed in B), <code>+</code> (plus&#8201;&#8212;&#8201;missing in A but
 4167 added to B), or <code>" "</code> (space&#8201;&#8212;&#8201;unchanged) prefix, this format
 4168 compares two or more files file1, file2,&#8230; with one file X, and
 4169 shows how X differs from each of fileN.  One column for each of
 4170 fileN is prepended to the output line to note how X&#8217;s line is
 4171 different from it.</p></div>
 4172 <div class="paragraph"><p>A <code>-</code> character in the column N means that the line appears in
 4173 fileN but it does not appear in the result.  A <code>+</code> character
 4174 in the column N means that the line appears in the result,
 4175 and fileN does not have that line (in other words, the line was
 4176 added, from the point of view of that parent).</p></div>
 4177 <div class="paragraph"><p>In the above example output, the function signature was changed
 4178 from both files (hence two <code>-</code> removals from both file1 and
 4179 file2, plus <code>++</code> to mean one line that was added does not appear
 4180 in either file1 or file2).  Also eight other lines are the same
 4181 from file1 but do not appear in file2 (hence prefixed with <code>+</code>).</p></div>
 4182 <div class="paragraph"><p>When shown by <code>git diff-tree -c</code>, it compares the parents of a
 4183 merge commit with the merge result (i.e. file1..fileN are the
 4184 parents).  When shown by <code>git diff-files -c</code>, it compares the
 4185 two unresolved merge parents with the working tree file
 4186 (i.e. file1 is stage 2 aka "our version", file2 is stage 3 aka
 4187 "their version").</p></div>
 4188 </div>
 4189 </div>
 4190 <div class="sect1">
 4191 <h2 id="_examples">EXAMPLES</h2>
 4192 <div class="sectionbody">
 4193 <div class="dlist"><dl>
 4194 <dt class="hdlist1">
 4195 <code>git log --no-merges</code>
 4196 </dt>
 4197 <dd>
 4198 <p>
 4199         Show the whole commit history, but skip any merges
 4200 </p>
 4201 </dd>
 4202 <dt class="hdlist1">
 4203 <code>git log v2.6.12.. include/scsi drivers/scsi</code>
 4204 </dt>
 4205 <dd>
 4206 <p>
 4207         Show all commits since version <em>v2.6.12</em> that changed any file
 4208         in the <code>include/scsi</code> or <code>drivers/scsi</code> subdirectories
 4209 </p>
 4210 </dd>
 4211 <dt class="hdlist1">
 4212 <code>git log --since="2 weeks ago" -- gitk</code>
 4213 </dt>
 4214 <dd>
 4215 <p>
 4216         Show the changes during the last two weeks to the file <em>gitk</em>.
 4217         The <code>--</code> is necessary to avoid confusion with the <strong>branch</strong> named
 4218         <em>gitk</em>
 4219 </p>
 4220 </dd>
 4221 <dt class="hdlist1">
 4222 <code>git log --name-status release..test</code>
 4223 </dt>
 4224 <dd>
 4225 <p>
 4226         Show the commits that are in the "test" branch but not yet
 4227         in the "release" branch, along with the list of paths
 4228         each commit modifies.
 4229 </p>
 4230 </dd>
 4231 <dt class="hdlist1">
 4232 <code>git log --follow builtin/rev-list.c</code>
 4233 </dt>
 4234 <dd>
 4235 <p>
 4236         Shows the commits that changed <code>builtin/rev-list.c</code>, including
 4237         those commits that occurred before the file was given its
 4238         present name.
 4239 </p>
 4240 </dd>
 4241 <dt class="hdlist1">
 4242 <code>git log --branches --not --remotes=origin</code>
 4243 </dt>
 4244 <dd>
 4245 <p>
 4246         Shows all commits that are in any of local branches but not in
 4247         any of remote-tracking branches for <em>origin</em> (what you have that
 4248         origin doesn&#8217;t).
 4249 </p>
 4250 </dd>
 4251 <dt class="hdlist1">
 4252 <code>git log master --not --remotes=*/master</code>
 4253 </dt>
 4254 <dd>
 4255 <p>
 4256         Shows all commits that are in local master but not in any remote
 4257         repository master branches.
 4258 </p>
 4259 </dd>
 4260 <dt class="hdlist1">
 4261 <code>git log -p -m --first-parent</code>
 4262 </dt>
 4263 <dd>
 4264 <p>
 4265         Shows the history including change diffs, but only from the
 4266         &#8220;main branch&#8221; perspective, skipping commits that come from merged
 4267         branches, and showing full diffs of changes introduced by the merges.
 4268         This makes sense only when following a strict policy of merging all
 4269         topic branches when staying on a single integration branch.
 4270 </p>
 4271 </dd>
 4272 <dt class="hdlist1">
 4273 <code>git log -L '/int main/',/^}/:main.c</code>
 4274 </dt>
 4275 <dd>
 4276 <p>
 4277         Shows how the function <code>main()</code> in the file <code>main.c</code> evolved
 4278         over time.
 4279 </p>
 4280 </dd>
 4281 <dt class="hdlist1">
 4282 <code>git log -3</code>
 4283 </dt>
 4284 <dd>
 4285 <p>
 4286         Limits the number of commits to show to 3.
 4287 </p>
 4288 </dd>
 4289 </dl></div>
 4290 </div>
 4291 </div>
 4292 <div class="sect1">
 4293 <h2 id="_discussion">DISCUSSION</h2>
 4294 <div class="sectionbody">
 4295 <div class="paragraph"><p>Git is to some extent character encoding agnostic.</p></div>
 4296 <div class="ulist"><ul>
 4297 <li>
 4298 <p>
 4299 The contents of the blob objects are uninterpreted sequences
 4300    of bytes.  There is no encoding translation at the core
 4301    level.
 4302 </p>
 4303 </li>
 4304 <li>
 4305 <p>
 4306 Path names are encoded in UTF-8 normalization form C. This
 4307    applies to tree objects, the index file, ref names, as well as
 4308    path names in command line arguments, environment variables
 4309    and config files (<code>.git/config</code> (see <a href="git-config.html">git-config(1)</a>),
 4310    <a href="gitignore.html">gitignore(5)</a>, <a href="gitattributes.html">gitattributes(5)</a> and
 4311    <a href="gitmodules.html">gitmodules(5)</a>).
 4312 </p>
 4313 <div class="paragraph"><p>Note that Git at the core level treats path names simply as
 4314 sequences of non-NUL bytes, there are no path name encoding
 4315 conversions (except on Mac and Windows). Therefore, using
 4316 non-ASCII path names will mostly work even on platforms and file
 4317 systems that use legacy extended ASCII encodings. However,
 4318 repositories created on such systems will not work properly on
 4319 UTF-8-based systems (e.g. Linux, Mac, Windows) and vice versa.
 4320 Additionally, many Git-based tools simply assume path names to
 4321 be UTF-8 and will fail to display other encodings correctly.</p></div>
 4322 </li>
 4323 <li>
 4324 <p>
 4325 Commit log messages are typically encoded in UTF-8, but other
 4326    extended ASCII encodings are also supported. This includes
 4327    ISO-8859-x, CP125x and many others, but <em>not</em> UTF-16/32,
 4328    EBCDIC and CJK multi-byte encodings (GBK, Shift-JIS, Big5,
 4329    EUC-x, CP9xx etc.).
 4330 </p>
 4331 </li>
 4332 </ul></div>
 4333 <div class="paragraph"><p>Although we encourage that the commit log messages are encoded
 4334 in UTF-8, both the core and Git Porcelain are designed not to
 4335 force UTF-8 on projects.  If all participants of a particular
 4336 project find it more convenient to use legacy encodings, Git
 4337 does not forbid it.  However, there are a few things to keep in
 4338 mind.</p></div>
 4339 <div class="olist arabic"><ol class="arabic">
 4340 <li>
 4341 <p>
 4342 <em>git commit</em> and <em>git commit-tree</em> issues
 4343   a warning if the commit log message given to it does not look
 4344   like a valid UTF-8 string, unless you explicitly say your
 4345   project uses a legacy encoding.  The way to say this is to
 4346   have i18n.commitencoding in <code>.git/config</code> file, like this:
 4347 </p>
 4348 <div class="listingblock">
 4349 <div class="content">
 4350 <pre><code>[i18n]
 4351         commitEncoding = ISO-8859-1</code></pre>
 4352 </div></div>
 4353 <div class="paragraph"><p>Commit objects created with the above setting record the value
 4354 of <code>i18n.commitEncoding</code> in its <code>encoding</code> header.  This is to
 4355 help other people who look at them later.  Lack of this header
 4356 implies that the commit log message is encoded in UTF-8.</p></div>
 4357 </li>
 4358 <li>
 4359 <p>
 4360 <em>git log</em>, <em>git show</em>, <em>git blame</em> and friends look at the
 4361   <code>encoding</code> header of a commit object, and try to re-code the
 4362   log message into UTF-8 unless otherwise specified.  You can
 4363   specify the desired output encoding with
 4364   <code>i18n.logOutputEncoding</code> in <code>.git/config</code> file, like this:
 4365 </p>
 4366 <div class="listingblock">
 4367 <div class="content">
 4368 <pre><code>[i18n]
 4369         logOutputEncoding = ISO-8859-1</code></pre>
 4370 </div></div>
 4371 <div class="paragraph"><p>If you do not have this configuration variable, the value of
 4372 <code>i18n.commitEncoding</code> is used instead.</p></div>
 4373 </li>
 4374 </ol></div>
 4375 <div class="paragraph"><p>Note that we deliberately chose not to re-code the commit log
 4376 message when a commit is made to force UTF-8 at the commit
 4377 object level, because re-coding to UTF-8 is not necessarily a
 4378 reversible operation.</p></div>
 4379 </div>
 4380 </div>
 4381 <div class="sect1">
 4382 <h2 id="_configuration">CONFIGURATION</h2>
 4383 <div class="sectionbody">
 4384 <div class="paragraph"><p>See <a href="git-config.html">git-config(1)</a> for core variables and <a href="git-diff.html">git-diff(1)</a>
 4385 for settings related to diff generation.</p></div>
 4386 <div class="dlist"><dl>
 4387 <dt class="hdlist1">
 4388 format.pretty
 4389 </dt>
 4390 <dd>
 4391 <p>
 4392         Default for the <code>--format</code> option.  (See <em>Pretty Formats</em> above.)
 4393         Defaults to <code>medium</code>.
 4394 </p>
 4395 </dd>
 4396 <dt class="hdlist1">
 4397 i18n.logOutputEncoding
 4398 </dt>
 4399 <dd>
 4400 <p>
 4401         Encoding to use when displaying logs.  (See <em>Discussion</em> above.)
 4402         Defaults to the value of <code>i18n.commitEncoding</code> if set, and UTF-8
 4403         otherwise.
 4404 </p>
 4405 </dd>
 4406 <dt class="hdlist1">
 4407 log.date
 4408 </dt>
 4409 <dd>
 4410 <p>
 4411         Default format for human-readable dates.  (Compare the
 4412         <code>--date</code> option.)  Defaults to "default", which means to write
 4413         dates like <code>Sat May 8 19:35:34 2010 -0500</code>.
 4414 </p>
 4415 </dd>
 4416 <dt class="hdlist1">
 4417 log.follow
 4418 </dt>
 4419 <dd>
 4420 <p>
 4421         If <code>true</code>, <code>git log</code> will act as if the <code>--follow</code> option was used when
 4422         a single &lt;path&gt; is given.  This has the same limitations as <code>--follow</code>,
 4423         i.e. it cannot be used to follow multiple files and does not work well
 4424         on non-linear history.
 4425 </p>
 4426 </dd>
 4427 <dt class="hdlist1">
 4428 log.showRoot
 4429 </dt>
 4430 <dd>
 4431 <p>
 4432         If <code>false</code>, <code>git log</code> and related commands will not treat the
 4433         initial commit as a big creation event.  Any root commits in
 4434         <code>git log -p</code> output would be shown without a diff attached.
 4435         The default is <code>true</code>.
 4436 </p>
 4437 </dd>
 4438 <dt class="hdlist1">
 4439 log.showSignature
 4440 </dt>
 4441 <dd>
 4442 <p>
 4443         If <code>true</code>, <code>git log</code> and related commands will act as if the
 4444         <code>--show-signature</code> option was passed to them.
 4445 </p>
 4446 </dd>
 4447 <dt class="hdlist1">
 4448 mailmap.*
 4449 </dt>
 4450 <dd>
 4451 <p>
 4452         See <a href="git-shortlog.html">git-shortlog(1)</a>.
 4453 </p>
 4454 </dd>
 4455 <dt class="hdlist1">
 4456 notes.displayRef
 4457 </dt>
 4458 <dd>
 4459 <p>
 4460         Which refs, in addition to the default set by <code>core.notesRef</code>
 4461         or <code>GIT_NOTES_REF</code>, to read notes from when showing commit
 4462         messages with the <code>log</code> family of commands.  See
 4463         <a href="git-notes.html">git-notes(1)</a>.
 4464 </p>
 4465 <div class="paragraph"><p>May be an unabbreviated ref name or a glob and may be specified
 4466 multiple times.  A warning will be issued for refs that do not exist,
 4467 but a glob that does not match any refs is silently ignored.</p></div>
 4468 <div class="paragraph"><p>This setting can be disabled by the <code>--no-notes</code> option,
 4469 overridden by the <code>GIT_NOTES_DISPLAY_REF</code> environment variable,
 4470 and overridden by the <code>--notes=&lt;ref&gt;</code> option.</p></div>
 4471 </dd>
 4472 </dl></div>
 4473 </div>
 4474 </div>
 4475 <div class="sect1">
 4476 <h2 id="_git">GIT</h2>
 4477 <div class="sectionbody">
 4478 <div class="paragraph"><p>Part of the <a href="git.html">git(1)</a> suite</p></div>
 4479 </div>
 4480 </div>
 4481 </div>
 4482 <div id="footnotes"><hr /></div>
 4483 <div id="footer">
 4484 <div id="footer-text">
 4485 Last updated
 4486  2018-12-10 16:43:18 JST
 4487 </div>
 4488 </div>
 4489 </body>
 4490 </html>