Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 1 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" |
| 2 | "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> |
| 3 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> |
| 4 | <head> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 5 | <meta http-equiv="Content-Type" content="application/xhtml+xml; charset=UTF-8" /> |
| 6 | <meta name="generator" content="AsciiDoc 8.6.8" /> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 7 | <title>git-rev-list(1)</title> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 8 | <style type="text/css"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 9 | /* Shared CSS for AsciiDoc xhtml11 and html5 backends */ |
| 10 | |
| 11 | /* Default font. */ |
| 12 | body { |
| 13 | font-family: Georgia,serif; |
| 14 | } |
| 15 | |
| 16 | /* Title font. */ |
| 17 | h1, h2, h3, h4, h5, h6, |
| 18 | div.title, caption.title, |
| 19 | thead, p.table.header, |
| 20 | #toctitle, |
| 21 | #author, #revnumber, #revdate, #revremark, |
| 22 | #footer { |
| 23 | font-family: Arial,Helvetica,sans-serif; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 24 | } |
| 25 | |
| 26 | body { |
| 27 | margin: 1em 5% 1em 5%; |
| 28 | } |
| 29 | |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 30 | a { |
| 31 | color: blue; |
| 32 | text-decoration: underline; |
| 33 | } |
| 34 | a:visited { |
| 35 | color: fuchsia; |
| 36 | } |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 37 | |
| 38 | em { |
| 39 | font-style: italic; |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 40 | color: navy; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 41 | } |
| 42 | |
| 43 | strong { |
| 44 | font-weight: bold; |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 45 | color: #083194; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 46 | } |
| 47 | |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 48 | h1, h2, h3, h4, h5, h6 { |
| 49 | color: #527bbd; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 50 | margin-top: 1.2em; |
| 51 | margin-bottom: 0.5em; |
| 52 | line-height: 1.3; |
| 53 | } |
| 54 | |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 55 | h1, h2, h3 { |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 56 | border-bottom: 2px solid silver; |
| 57 | } |
| 58 | h2 { |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 59 | padding-top: 0.5em; |
| 60 | } |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 61 | h3 { |
| 62 | float: left; |
| 63 | } |
| 64 | h3 + * { |
| 65 | clear: left; |
| 66 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 67 | h5 { |
| 68 | font-size: 1.0em; |
| 69 | } |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 70 | |
| 71 | div.sectionbody { |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 72 | margin-left: 0; |
| 73 | } |
| 74 | |
| 75 | hr { |
| 76 | border: 1px solid silver; |
| 77 | } |
| 78 | |
| 79 | p { |
| 80 | margin-top: 0.5em; |
| 81 | margin-bottom: 0.5em; |
| 82 | } |
| 83 | |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 84 | ul, ol, li > p { |
| 85 | margin-top: 0; |
| 86 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 87 | ul > li { color: #aaa; } |
| 88 | ul > li > * { color: black; } |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 89 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 90 | .monospaced, code, pre { |
| 91 | font-family: "Courier New", Courier, monospace; |
| 92 | font-size: inherit; |
| 93 | color: navy; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 94 | padding: 0; |
| 95 | margin: 0; |
| 96 | } |
| 97 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 98 | |
| 99 | #author { |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 100 | color: #527bbd; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 101 | font-weight: bold; |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 102 | font-size: 1.1em; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 103 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 104 | #email { |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 105 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 106 | #revnumber, #revdate, #revremark { |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 107 | } |
| 108 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 109 | #footer { |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 110 | font-size: small; |
| 111 | border-top: 2px solid silver; |
| 112 | padding-top: 0.5em; |
| 113 | margin-top: 4.0em; |
| 114 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 115 | #footer-text { |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 116 | float: left; |
| 117 | padding-bottom: 0.5em; |
| 118 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 119 | #footer-badges { |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 120 | float: right; |
| 121 | padding-bottom: 0.5em; |
| 122 | } |
| 123 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 124 | #preamble { |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 125 | margin-top: 1.5em; |
| 126 | margin-bottom: 1.5em; |
| 127 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 128 | div.imageblock, div.exampleblock, div.verseblock, |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 129 | div.quoteblock, div.literalblock, div.listingblock, div.sidebarblock, |
| 130 | div.admonitionblock { |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 131 | margin-top: 1.0em; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 132 | margin-bottom: 1.5em; |
| 133 | } |
| 134 | div.admonitionblock { |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 135 | margin-top: 2.0em; |
| 136 | margin-bottom: 2.0em; |
| 137 | margin-right: 10%; |
| 138 | color: #606060; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 139 | } |
| 140 | |
| 141 | div.content { /* Block element content. */ |
| 142 | padding: 0; |
| 143 | } |
| 144 | |
| 145 | /* Block element titles. */ |
| 146 | div.title, caption.title { |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 147 | color: #527bbd; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 148 | font-weight: bold; |
| 149 | text-align: left; |
| 150 | margin-top: 1.0em; |
| 151 | margin-bottom: 0.5em; |
| 152 | } |
| 153 | div.title + * { |
| 154 | margin-top: 0; |
| 155 | } |
| 156 | |
| 157 | td div.title:first-child { |
| 158 | margin-top: 0.0em; |
| 159 | } |
| 160 | div.content div.title:first-child { |
| 161 | margin-top: 0.0em; |
| 162 | } |
| 163 | div.content + div.title { |
| 164 | margin-top: 0.0em; |
| 165 | } |
| 166 | |
| 167 | div.sidebarblock > div.content { |
| 168 | background: #ffffee; |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 169 | border: 1px solid #dddddd; |
| 170 | border-left: 4px solid #f0f0f0; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 171 | padding: 0.5em; |
| 172 | } |
| 173 | |
| 174 | div.listingblock > div.content { |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 175 | border: 1px solid #dddddd; |
| 176 | border-left: 5px solid #f0f0f0; |
| 177 | background: #f8f8f8; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 178 | padding: 0.5em; |
| 179 | } |
| 180 | |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 181 | div.quoteblock, div.verseblock { |
| 182 | padding-left: 1.0em; |
| 183 | margin-left: 1.0em; |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 184 | margin-right: 10%; |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 185 | border-left: 5px solid #f0f0f0; |
| 186 | color: #888; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 187 | } |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 188 | |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 189 | div.quoteblock > div.attribution { |
| 190 | padding-top: 0.5em; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 191 | text-align: right; |
| 192 | } |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 193 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 194 | div.verseblock > pre.content { |
| 195 | font-family: inherit; |
| 196 | font-size: inherit; |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 197 | } |
| 198 | div.verseblock > div.attribution { |
| 199 | padding-top: 0.75em; |
| 200 | text-align: left; |
| 201 | } |
| 202 | /* DEPRECATED: Pre version 8.2.7 verse style literal block. */ |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 203 | div.verseblock + div.attribution { |
| 204 | text-align: left; |
| 205 | } |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 206 | |
| 207 | div.admonitionblock .icon { |
| 208 | vertical-align: top; |
| 209 | font-size: 1.1em; |
| 210 | font-weight: bold; |
| 211 | text-decoration: underline; |
| 212 | color: #527bbd; |
| 213 | padding-right: 0.5em; |
| 214 | } |
| 215 | div.admonitionblock td.content { |
| 216 | padding-left: 0.5em; |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 217 | border-left: 3px solid #dddddd; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 218 | } |
| 219 | |
| 220 | div.exampleblock > div.content { |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 221 | border-left: 3px solid #dddddd; |
| 222 | padding-left: 0.5em; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 223 | } |
| 224 | |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 225 | div.imageblock div.content { padding-left: 0; } |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 226 | span.image img { border-style: none; } |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 227 | a.image:visited { color: white; } |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 228 | |
| 229 | dl { |
| 230 | margin-top: 0.8em; |
| 231 | margin-bottom: 0.8em; |
| 232 | } |
| 233 | dt { |
| 234 | margin-top: 0.5em; |
| 235 | margin-bottom: 0; |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 236 | font-style: normal; |
| 237 | color: navy; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 238 | } |
| 239 | dd > *:first-child { |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 240 | margin-top: 0.1em; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 241 | } |
| 242 | |
| 243 | ul, ol { |
| 244 | list-style-position: outside; |
| 245 | } |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 246 | ol.arabic { |
| 247 | list-style-type: decimal; |
| 248 | } |
| 249 | ol.loweralpha { |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 250 | list-style-type: lower-alpha; |
| 251 | } |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 252 | ol.upperalpha { |
| 253 | list-style-type: upper-alpha; |
| 254 | } |
| 255 | ol.lowerroman { |
| 256 | list-style-type: lower-roman; |
| 257 | } |
| 258 | ol.upperroman { |
| 259 | list-style-type: upper-roman; |
| 260 | } |
| 261 | |
| 262 | div.compact ul, div.compact ol, |
| 263 | div.compact p, div.compact p, |
| 264 | div.compact div, div.compact div { |
| 265 | margin-top: 0.1em; |
| 266 | margin-bottom: 0.1em; |
| 267 | } |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 268 | |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 269 | tfoot { |
| 270 | font-weight: bold; |
| 271 | } |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 272 | td > div.verse { |
| 273 | white-space: pre; |
| 274 | } |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 275 | |
| 276 | div.hdlist { |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 277 | margin-top: 0.8em; |
| 278 | margin-bottom: 0.8em; |
| 279 | } |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 280 | div.hdlist tr { |
| 281 | padding-bottom: 15px; |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 282 | } |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 283 | dt.hdlist1.strong, td.hdlist1.strong { |
| 284 | font-weight: bold; |
| 285 | } |
| 286 | td.hdlist1 { |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 287 | vertical-align: top; |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 288 | font-style: normal; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 289 | padding-right: 0.8em; |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 290 | color: navy; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 291 | } |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 292 | td.hdlist2 { |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 293 | vertical-align: top; |
| 294 | } |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 295 | div.hdlist.compact tr { |
| 296 | margin: 0; |
| 297 | padding-bottom: 0; |
| 298 | } |
| 299 | |
| 300 | .comment { |
| 301 | background: yellow; |
| 302 | } |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 303 | |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 304 | .footnote, .footnoteref { |
| 305 | font-size: 0.8em; |
| 306 | } |
| 307 | |
| 308 | span.footnote, span.footnoteref { |
| 309 | vertical-align: super; |
| 310 | } |
| 311 | |
| 312 | #footnotes { |
| 313 | margin: 20px 0 20px 0; |
| 314 | padding: 7px 0 0 0; |
| 315 | } |
| 316 | |
| 317 | #footnotes div.footnote { |
| 318 | margin: 0 0 5px 0; |
| 319 | } |
| 320 | |
| 321 | #footnotes hr { |
| 322 | border: none; |
| 323 | border-top: 1px solid silver; |
| 324 | height: 1px; |
| 325 | text-align: left; |
| 326 | margin-left: 0; |
| 327 | width: 20%; |
| 328 | min-width: 100px; |
| 329 | } |
| 330 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 331 | div.colist td { |
| 332 | padding-right: 0.5em; |
| 333 | padding-bottom: 0.3em; |
| 334 | vertical-align: top; |
| 335 | } |
| 336 | div.colist td img { |
| 337 | margin-top: 0.3em; |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 338 | } |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 339 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 340 | @media print { |
| 341 | #footer-badges { display: none; } |
| 342 | } |
| 343 | |
| 344 | #toc { |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 345 | margin-bottom: 2.5em; |
| 346 | } |
| 347 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 348 | #toctitle { |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 349 | color: #527bbd; |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 350 | font-size: 1.1em; |
| 351 | font-weight: bold; |
| 352 | margin-top: 1.0em; |
| 353 | margin-bottom: 0.1em; |
| 354 | } |
| 355 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 356 | div.toclevel0, div.toclevel1, div.toclevel2, div.toclevel3, div.toclevel4 { |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 357 | margin-top: 0; |
| 358 | margin-bottom: 0; |
| 359 | } |
| 360 | div.toclevel2 { |
| 361 | margin-left: 2em; |
| 362 | font-size: 0.9em; |
| 363 | } |
| 364 | div.toclevel3 { |
| 365 | margin-left: 4em; |
| 366 | font-size: 0.9em; |
| 367 | } |
| 368 | div.toclevel4 { |
| 369 | margin-left: 6em; |
| 370 | font-size: 0.9em; |
| 371 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 372 | |
| 373 | span.aqua { color: aqua; } |
| 374 | span.black { color: black; } |
| 375 | span.blue { color: blue; } |
| 376 | span.fuchsia { color: fuchsia; } |
| 377 | span.gray { color: gray; } |
| 378 | span.green { color: green; } |
| 379 | span.lime { color: lime; } |
| 380 | span.maroon { color: maroon; } |
| 381 | span.navy { color: navy; } |
| 382 | span.olive { color: olive; } |
| 383 | span.purple { color: purple; } |
| 384 | span.red { color: red; } |
| 385 | span.silver { color: silver; } |
| 386 | span.teal { color: teal; } |
| 387 | span.white { color: white; } |
| 388 | span.yellow { color: yellow; } |
| 389 | |
| 390 | span.aqua-background { background: aqua; } |
| 391 | span.black-background { background: black; } |
| 392 | span.blue-background { background: blue; } |
| 393 | span.fuchsia-background { background: fuchsia; } |
| 394 | span.gray-background { background: gray; } |
| 395 | span.green-background { background: green; } |
| 396 | span.lime-background { background: lime; } |
| 397 | span.maroon-background { background: maroon; } |
| 398 | span.navy-background { background: navy; } |
| 399 | span.olive-background { background: olive; } |
| 400 | span.purple-background { background: purple; } |
| 401 | span.red-background { background: red; } |
| 402 | span.silver-background { background: silver; } |
| 403 | span.teal-background { background: teal; } |
| 404 | span.white-background { background: white; } |
| 405 | span.yellow-background { background: yellow; } |
| 406 | |
| 407 | span.big { font-size: 2em; } |
| 408 | span.small { font-size: 0.6em; } |
| 409 | |
| 410 | span.underline { text-decoration: underline; } |
| 411 | span.overline { text-decoration: overline; } |
| 412 | span.line-through { text-decoration: line-through; } |
| 413 | |
| 414 | div.unbreakable { page-break-inside: avoid; } |
| 415 | |
| 416 | |
| 417 | /* |
| 418 | * xhtml11 specific |
| 419 | * |
| 420 | * */ |
| 421 | |
| 422 | div.tableblock { |
| 423 | margin-top: 1.0em; |
| 424 | margin-bottom: 1.5em; |
| 425 | } |
| 426 | div.tableblock > table { |
| 427 | border: 3px solid #527bbd; |
| 428 | } |
| 429 | thead, p.table.header { |
| 430 | font-weight: bold; |
| 431 | color: #527bbd; |
| 432 | } |
| 433 | p.table { |
| 434 | margin-top: 0; |
| 435 | } |
| 436 | /* Because the table frame attribute is overriden by CSS in most browsers. */ |
| 437 | div.tableblock > table[frame="void"] { |
| 438 | border-style: none; |
| 439 | } |
| 440 | div.tableblock > table[frame="hsides"] { |
| 441 | border-left-style: none; |
| 442 | border-right-style: none; |
| 443 | } |
| 444 | div.tableblock > table[frame="vsides"] { |
| 445 | border-top-style: none; |
| 446 | border-bottom-style: none; |
| 447 | } |
| 448 | |
| 449 | |
| 450 | /* |
| 451 | * html5 specific |
| 452 | * |
| 453 | * */ |
| 454 | |
| 455 | table.tableblock { |
| 456 | margin-top: 1.0em; |
| 457 | margin-bottom: 1.5em; |
| 458 | } |
| 459 | thead, p.tableblock.header { |
| 460 | font-weight: bold; |
| 461 | color: #527bbd; |
| 462 | } |
| 463 | p.tableblock { |
| 464 | margin-top: 0; |
| 465 | } |
| 466 | table.tableblock { |
| 467 | border-width: 3px; |
| 468 | border-spacing: 0px; |
| 469 | border-style: solid; |
| 470 | border-color: #527bbd; |
| 471 | border-collapse: collapse; |
| 472 | } |
| 473 | th.tableblock, td.tableblock { |
| 474 | border-width: 1px; |
| 475 | padding: 4px; |
| 476 | border-style: solid; |
| 477 | border-color: #527bbd; |
| 478 | } |
| 479 | |
| 480 | table.tableblock.frame-topbot { |
| 481 | border-left-style: hidden; |
| 482 | border-right-style: hidden; |
| 483 | } |
| 484 | table.tableblock.frame-sides { |
| 485 | border-top-style: hidden; |
| 486 | border-bottom-style: hidden; |
| 487 | } |
| 488 | table.tableblock.frame-none { |
| 489 | border-style: hidden; |
| 490 | } |
| 491 | |
| 492 | th.tableblock.halign-left, td.tableblock.halign-left { |
| 493 | text-align: left; |
| 494 | } |
| 495 | th.tableblock.halign-center, td.tableblock.halign-center { |
| 496 | text-align: center; |
| 497 | } |
| 498 | th.tableblock.halign-right, td.tableblock.halign-right { |
| 499 | text-align: right; |
| 500 | } |
| 501 | |
| 502 | th.tableblock.valign-top, td.tableblock.valign-top { |
| 503 | vertical-align: top; |
| 504 | } |
| 505 | th.tableblock.valign-middle, td.tableblock.valign-middle { |
| 506 | vertical-align: middle; |
| 507 | } |
| 508 | th.tableblock.valign-bottom, td.tableblock.valign-bottom { |
| 509 | vertical-align: bottom; |
| 510 | } |
| 511 | |
| 512 | |
| 513 | /* |
| 514 | * manpage specific |
| 515 | * |
| 516 | * */ |
| 517 | |
| 518 | body.manpage h1 { |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 519 | padding-top: 0.5em; |
| 520 | padding-bottom: 0.5em; |
| 521 | border-top: 2px solid silver; |
| 522 | border-bottom: 2px solid silver; |
| 523 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 524 | body.manpage h2 { |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 525 | border-style: none; |
| 526 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 527 | body.manpage div.sectionbody { |
| 528 | margin-left: 3em; |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 529 | } |
| 530 | |
| 531 | @media print { |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 532 | body.manpage div#toc { display: none; } |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 533 | } |
| 534 | |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 535 | |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 536 | </style> |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 537 | <script type="text/javascript"> |
| 538 | /*<![CDATA[*/ |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 539 | var asciidoc = { // Namespace. |
| 540 | |
| 541 | ///////////////////////////////////////////////////////////////////// |
| 542 | // Table Of Contents generator |
| 543 | ///////////////////////////////////////////////////////////////////// |
| 544 | |
| 545 | /* Author: Mihai Bazon, September 2002 |
| 546 | * http://students.infoiasi.ro/~mishoo |
| 547 | * |
| 548 | * Table Of Content generator |
| 549 | * Version: 0.4 |
| 550 | * |
| 551 | * Feel free to use this script under the terms of the GNU General Public |
| 552 | * License, as long as you do not remove or alter this notice. |
| 553 | */ |
| 554 | |
| 555 | /* modified by Troy D. Hanson, September 2006. License: GPL */ |
| 556 | /* modified by Stuart Rackham, 2006, 2009. License: GPL */ |
| 557 | |
| 558 | // toclevels = 1..4. |
| 559 | toc: function (toclevels) { |
| 560 | |
| 561 | function getText(el) { |
| 562 | var text = ""; |
| 563 | for (var i = el.firstChild; i != null; i = i.nextSibling) { |
| 564 | if (i.nodeType == 3 /* Node.TEXT_NODE */) // IE doesn't speak constants. |
| 565 | text += i.data; |
| 566 | else if (i.firstChild != null) |
| 567 | text += getText(i); |
| 568 | } |
| 569 | return text; |
| 570 | } |
| 571 | |
| 572 | function TocEntry(el, text, toclevel) { |
| 573 | this.element = el; |
| 574 | this.text = text; |
| 575 | this.toclevel = toclevel; |
| 576 | } |
| 577 | |
| 578 | function tocEntries(el, toclevels) { |
| 579 | var result = new Array; |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 580 | var re = new RegExp('[hH]([1-'+(toclevels+1)+'])'); |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 581 | // Function that scans the DOM tree for header elements (the DOM2 |
| 582 | // nodeIterator API would be a better technique but not supported by all |
| 583 | // browsers). |
| 584 | var iterate = function (el) { |
| 585 | for (var i = el.firstChild; i != null; i = i.nextSibling) { |
| 586 | if (i.nodeType == 1 /* Node.ELEMENT_NODE */) { |
| 587 | var mo = re.exec(i.tagName); |
| 588 | if (mo && (i.getAttribute("class") || i.getAttribute("className")) != "float") { |
| 589 | result[result.length] = new TocEntry(i, getText(i), mo[1]-1); |
| 590 | } |
| 591 | iterate(i); |
| 592 | } |
| 593 | } |
| 594 | } |
| 595 | iterate(el); |
| 596 | return result; |
| 597 | } |
| 598 | |
| 599 | var toc = document.getElementById("toc"); |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 600 | if (!toc) { |
| 601 | return; |
| 602 | } |
| 603 | |
| 604 | // Delete existing TOC entries in case we're reloading the TOC. |
| 605 | var tocEntriesToRemove = []; |
| 606 | var i; |
| 607 | for (i = 0; i < toc.childNodes.length; i++) { |
| 608 | var entry = toc.childNodes[i]; |
| 609 | if (entry.nodeName.toLowerCase() == 'div' |
| 610 | && entry.getAttribute("class") |
| 611 | && entry.getAttribute("class").match(/^toclevel/)) |
| 612 | tocEntriesToRemove.push(entry); |
| 613 | } |
| 614 | for (i = 0; i < tocEntriesToRemove.length; i++) { |
| 615 | toc.removeChild(tocEntriesToRemove[i]); |
| 616 | } |
| 617 | |
| 618 | // Rebuild TOC entries. |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 619 | var entries = tocEntries(document.getElementById("content"), toclevels); |
| 620 | for (var i = 0; i < entries.length; ++i) { |
| 621 | var entry = entries[i]; |
| 622 | if (entry.element.id == "") |
| 623 | entry.element.id = "_toc_" + i; |
| 624 | var a = document.createElement("a"); |
| 625 | a.href = "#" + entry.element.id; |
| 626 | a.appendChild(document.createTextNode(entry.text)); |
| 627 | var div = document.createElement("div"); |
| 628 | div.appendChild(a); |
| 629 | div.className = "toclevel" + entry.toclevel; |
| 630 | toc.appendChild(div); |
| 631 | } |
| 632 | if (entries.length == 0) |
| 633 | toc.parentNode.removeChild(toc); |
| 634 | }, |
| 635 | |
| 636 | |
| 637 | ///////////////////////////////////////////////////////////////////// |
| 638 | // Footnotes generator |
| 639 | ///////////////////////////////////////////////////////////////////// |
| 640 | |
| 641 | /* Based on footnote generation code from: |
| 642 | * http://www.brandspankingnew.net/archive/2005/07/format_footnote.html |
| 643 | */ |
| 644 | |
| 645 | footnotes: function () { |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 646 | // Delete existing footnote entries in case we're reloading the footnodes. |
| 647 | var i; |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 648 | var noteholder = document.getElementById("footnotes"); |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 649 | if (!noteholder) { |
| 650 | return; |
| 651 | } |
| 652 | var entriesToRemove = []; |
| 653 | for (i = 0; i < noteholder.childNodes.length; i++) { |
| 654 | var entry = noteholder.childNodes[i]; |
| 655 | if (entry.nodeName.toLowerCase() == 'div' && entry.getAttribute("class") == "footnote") |
| 656 | entriesToRemove.push(entry); |
| 657 | } |
| 658 | for (i = 0; i < entriesToRemove.length; i++) { |
| 659 | noteholder.removeChild(entriesToRemove[i]); |
| 660 | } |
| 661 | |
| 662 | // Rebuild footnote entries. |
| 663 | var cont = document.getElementById("content"); |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 664 | var spans = cont.getElementsByTagName("span"); |
| 665 | var refs = {}; |
| 666 | var n = 0; |
| 667 | for (i=0; i<spans.length; i++) { |
| 668 | if (spans[i].className == "footnote") { |
| 669 | n++; |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 670 | var note = spans[i].getAttribute("data-note"); |
| 671 | if (!note) { |
| 672 | // Use [\s\S] in place of . so multi-line matches work. |
| 673 | // Because JavaScript has no s (dotall) regex flag. |
| 674 | note = spans[i].innerHTML.match(/\s*\[([\s\S]*)]\s*/)[1]; |
| 675 | spans[i].innerHTML = |
| 676 | "[<a id='_footnoteref_" + n + "' href='#_footnote_" + n + |
| 677 | "' title='View footnote' class='footnote'>" + n + "</a>]"; |
| 678 | spans[i].setAttribute("data-note", note); |
| 679 | } |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 680 | noteholder.innerHTML += |
| 681 | "<div class='footnote' id='_footnote_" + n + "'>" + |
| 682 | "<a href='#_footnoteref_" + n + "' title='Return to text'>" + |
| 683 | n + "</a>. " + note + "</div>"; |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 684 | var id =spans[i].getAttribute("id"); |
| 685 | if (id != null) refs["#"+id] = n; |
| 686 | } |
| 687 | } |
| 688 | if (n == 0) |
| 689 | noteholder.parentNode.removeChild(noteholder); |
| 690 | else { |
| 691 | // Process footnoterefs. |
| 692 | for (i=0; i<spans.length; i++) { |
| 693 | if (spans[i].className == "footnoteref") { |
| 694 | var href = spans[i].getElementsByTagName("a")[0].getAttribute("href"); |
| 695 | href = href.match(/#.*/)[0]; // Because IE return full URL. |
| 696 | n = refs[href]; |
| 697 | spans[i].innerHTML = |
| 698 | "[<a href='#_footnote_" + n + |
| 699 | "' title='View footnote' class='footnote'>" + n + "</a>]"; |
| 700 | } |
| 701 | } |
| 702 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 703 | }, |
| 704 | |
| 705 | install: function(toclevels) { |
| 706 | var timerId; |
| 707 | |
| 708 | function reinstall() { |
| 709 | asciidoc.footnotes(); |
| 710 | if (toclevels) { |
| 711 | asciidoc.toc(toclevels); |
| 712 | } |
| 713 | } |
| 714 | |
| 715 | function reinstallAndRemoveTimer() { |
| 716 | clearInterval(timerId); |
| 717 | reinstall(); |
| 718 | } |
| 719 | |
| 720 | timerId = setInterval(reinstall, 500); |
| 721 | if (document.addEventListener) |
| 722 | document.addEventListener("DOMContentLoaded", reinstallAndRemoveTimer, false); |
| 723 | else |
| 724 | window.onload = reinstallAndRemoveTimer; |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 725 | } |
| 726 | |
| 727 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 728 | asciidoc.install(); |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 729 | /*]]>*/ |
| 730 | </script> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 731 | </head> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 732 | <body class="manpage"> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 733 | <div id="header"> |
| 734 | <h1> |
| 735 | git-rev-list(1) Manual Page |
| 736 | </h1> |
| 737 | <h2>NAME</h2> |
| 738 | <div class="sectionbody"> |
| 739 | <p>git-rev-list - |
| 740 | Lists commit objects in reverse chronological order |
| 741 | </p> |
| 742 | </div> |
| 743 | </div> |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 744 | <div id="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 745 | <div class="sect1"> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 746 | <h2 id="_synopsis">SYNOPSIS</h2> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 747 | <div class="sectionbody"> |
Junio C Hamano | 235a91e | 2006-01-07 01:13:58 | [diff] [blame] | 748 | <div class="verseblock"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 749 | <pre class="content"><em>git rev-list</em> [ --max-count=<number> ] |
Junio C Hamano | d2179ef | 2010-10-22 04:12:17 | [diff] [blame] | 750 | [ --skip=<number> ] |
| 751 | [ --max-age=<timestamp> ] |
| 752 | [ --min-age=<timestamp> ] |
Junio C Hamano | 235a91e | 2006-01-07 01:13:58 | [diff] [blame] | 753 | [ --sparse ] |
Junio C Hamano | 934e178 | 2009-07-16 06:59:15 | [diff] [blame] | 754 | [ --merges ] |
Junio C Hamano | 235a91e | 2006-01-07 01:13:58 | [diff] [blame] | 755 | [ --no-merges ] |
Junio C Hamano | f32ce26 | 2011-03-27 07:35:11 | [diff] [blame] | 756 | [ --min-parents=<number> ] |
| 757 | [ --no-min-parents ] |
| 758 | [ --max-parents=<number> ] |
| 759 | [ --no-max-parents ] |
Junio C Hamano | 554da79 | 2007-12-27 03:29:58 | [diff] [blame] | 760 | [ --first-parent ] |
Junio C Hamano | 9be1897 | 2006-01-28 08:54:57 | [diff] [blame] | 761 | [ --remove-empty ] |
Junio C Hamano | ee695f2 | 2007-06-21 00:35:36 | [diff] [blame] | 762 | [ --full-history ] |
Junio C Hamano | 872c568 | 2006-07-07 06:05:40 | [diff] [blame] | 763 | [ --not ] |
Junio C Hamano | 235a91e | 2006-01-07 01:13:58 | [diff] [blame] | 764 | [ --all ] |
Junio C Hamano | d2179ef | 2010-10-22 04:12:17 | [diff] [blame] | 765 | [ --branches[=<pattern>] ] |
| 766 | [ --tags[=<pattern>] ] |
| 767 | [ --remotes[=<pattern>] ] |
| 768 | [ --glob=<glob-pattern> ] |
Junio C Hamano | 084228c | 2011-05-30 08:13:52 | [diff] [blame] | 769 | [ --ignore-missing ] |
Junio C Hamano | c9245d9 | 2006-09-06 09:35:46 | [diff] [blame] | 770 | [ --stdin ] |
Junio C Hamano | 8c5802d | 2007-11-15 00:13:36 | [diff] [blame] | 771 | [ --quiet ] |
Junio C Hamano | decf50e | 2006-03-05 10:51:14 | [diff] [blame] | 772 | [ --topo-order ] |
Junio C Hamano | 235a91e | 2006-01-07 01:13:58 | [diff] [blame] | 773 | [ --parents ] |
Junio C Hamano | ee695f2 | 2007-06-21 00:35:36 | [diff] [blame] | 774 | [ --timestamp ] |
Junio C Hamano | 5678d69 | 2007-04-06 00:51:43 | [diff] [blame] | 775 | [ --left-right ] |
Junio C Hamano | 9a2fb2d | 2011-03-23 05:40:15 | [diff] [blame] | 776 | [ --left-only ] |
| 777 | [ --right-only ] |
| 778 | [ --cherry-mark ] |
Junio C Hamano | d9e0e5d | 2007-04-14 16:22:04 | [diff] [blame] | 779 | [ --cherry-pick ] |
Junio C Hamano | 775a0f4 | 2006-12-31 01:19:14 | [diff] [blame] | 780 | [ --encoding[=<encoding>] ] |
Junio C Hamano | 47c1e3c | 2006-09-25 04:45:55 | [diff] [blame] | 781 | [ --(author|committer|grep)=<pattern> ] |
Junio C Hamano | a476efa | 2008-10-10 15:31:42 | [diff] [blame] | 782 | [ --regexp-ignore-case | -i ] |
| 783 | [ --extended-regexp | -E ] |
| 784 | [ --fixed-strings | -F ] |
Junio C Hamano | d2179ef | 2010-10-22 04:12:17 | [diff] [blame] | 785 | [ --date=(local|relative|default|iso|rfc|short) ] |
Junio C Hamano | 5f32776 | 2006-03-02 09:14:51 | [diff] [blame] | 786 | [ [--objects | --objects-edge] [ --unpacked ] ] |
Junio C Hamano | 235a91e | 2006-01-07 01:13:58 | [diff] [blame] | 787 | [ --pretty | --header ] |
| 788 | [ --bisect ] |
Junio C Hamano | 20f64da | 2007-04-04 18:38:30 | [diff] [blame] | 789 | [ --bisect-vars ] |
Junio C Hamano | 1974bf2 | 2007-10-31 05:57:20 | [diff] [blame] | 790 | [ --bisect-all ] |
Junio C Hamano | 859f3b4 | 2006-08-04 10:04:30 | [diff] [blame] | 791 | [ --merge ] |
Junio C Hamano | 053827f | 2007-02-14 07:23:58 | [diff] [blame] | 792 | [ --reverse ] |
Junio C Hamano | db450ba | 2007-01-21 08:57:14 | [diff] [blame] | 793 | [ --walk-reflogs ] |
Junio C Hamano | a196f6d | 2007-07-24 08:10:27 | [diff] [blame] | 794 | [ --no-walk ] [ --do-walk ] |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 795 | <commit>… [ -- <paths>… ]</pre> |
| 796 | <div class="attribution"> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 797 | </div></div> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 798 | </div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 799 | </div> |
| 800 | <div class="sect1"> |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 801 | <h2 id="_description">DESCRIPTION</h2> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 802 | <div class="sectionbody"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 803 | <div class="paragraph"><p>List commits that are reachable by following the <code>parent</code> links from the |
Junio C Hamano | 31cca16 | 2009-08-07 05:40:01 | [diff] [blame] | 804 | given commit(s), but exclude commits that are reachable from the one(s) |
| 805 | given with a <em>^</em> in front of them. The output is given in reverse |
| 806 | chronological order by default.</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 807 | <div class="paragraph"><p>You can think of this as a set operation. Commits given on the command |
Junio C Hamano | 31cca16 | 2009-08-07 05:40:01 | [diff] [blame] | 808 | line form a set of commits that are reachable from any of them, and then |
| 809 | commits reachable from any of the ones given with <em>^</em> in front are |
| 810 | subtracted from that set. The remaining commits are what comes out in the |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 811 | command’s output. Various other options and paths parameters can be used |
Junio C Hamano | 31cca16 | 2009-08-07 05:40:01 | [diff] [blame] | 812 | to further limit the result.</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 813 | <div class="paragraph"><p>Thus, the following command:</p></div> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 814 | <div class="listingblock"> |
| 815 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 816 | <pre><code> $ git rev-list foo bar ^baz</code></pre> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 817 | </div></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 818 | <div class="paragraph"><p>means "list all the commits which are reachable from <em>foo</em> or <em>bar</em>, but |
Junio C Hamano | 31cca16 | 2009-08-07 05:40:01 | [diff] [blame] | 819 | not from <em>baz</em>".</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 820 | <div class="paragraph"><p>A special notation "<em><commit1></em>..<em><commit2></em>" can be used as a |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 821 | short-hand for "^'<commit1>' <em><commit2></em>". For example, either of |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 822 | the following may be used interchangeably:</p></div> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 823 | <div class="listingblock"> |
| 824 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 825 | <pre><code> $ git rev-list origin..HEAD |
| 826 | $ git rev-list HEAD ^origin</code></pre> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 827 | </div></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 828 | <div class="paragraph"><p>Another special notation is "<em><commit1></em>…<em><commit2></em>" which is useful |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 829 | for merges. The resulting set of commits is the symmetric difference |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 830 | between the two operands. The following two commands are equivalent:</p></div> |
Junio C Hamano | 872c568 | 2006-07-07 06:05:40 | [diff] [blame] | 831 | <div class="listingblock"> |
| 832 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 833 | <pre><code> $ git rev-list A B --not $(git merge-base --all A B) |
| 834 | $ git rev-list A...B</code></pre> |
Junio C Hamano | 872c568 | 2006-07-07 06:05:40 | [diff] [blame] | 835 | </div></div> |
Junio C Hamano | 076ffcc | 2013-02-06 05:13:21 | [diff] [blame] | 836 | <div class="paragraph"><p><em>rev-list</em> is a very essential Git command, since it |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 837 | provides the ability to build and traverse commit ancestry graphs. For |
| 838 | this reason, it has a lot of different options that enables it to be |
Junio C Hamano | 1aa40d2 | 2010-01-21 17:46:43 | [diff] [blame] | 839 | used by commands as different as <em>git bisect</em> and |
| 840 | <em>git repack</em>.</p></div> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 841 | </div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 842 | </div> |
| 843 | <div class="sect1"> |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 844 | <h2 id="_options">OPTIONS</h2> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 845 | <div class="sectionbody"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 846 | <div class="sect2"> |
| 847 | <h3 id="_commit_limiting">Commit Limiting</h3> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 848 | <div class="paragraph"><p>Besides specifying a range of commits that should be listed using the |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 849 | special notations explained in the description, additional commit |
Junio C Hamano | 8ce35d7 | 2012-09-18 22:30:42 | [diff] [blame] | 850 | limiting may be applied.</p></div> |
| 851 | <div class="paragraph"><p>Using more options generally further limits the output (e.g. |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 852 | <code>--since=<date1></code> limits to commits newer than <code><date1></code>, and using it |
| 853 | with <code>--grep=<pattern></code> further limits to commits whose log message |
| 854 | has a line that matches <code><pattern></code>), unless otherwise noted.</p></div> |
Junio C Hamano | 8ce35d7 | 2012-09-18 22:30:42 | [diff] [blame] | 855 | <div class="paragraph"><p>Note that these are applied before commit |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 856 | ordering and formatting options, such as <code>--reverse</code>.</p></div> |
| 857 | <div class="openblock"> |
| 858 | <div class="content"> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 859 | <div class="dlist"><dl> |
| 860 | <dt class="hdlist1"> |
Junio C Hamano | 693e709 | 2012-09-12 22:56:53 | [diff] [blame] | 861 | -<number> |
| 862 | </dt> |
| 863 | <dt class="hdlist1"> |
| 864 | -n <number> |
Junio C Hamano | eb41599 | 2008-06-08 22:49:47 | [diff] [blame] | 865 | </dt> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 866 | <dt class="hdlist1"> |
Junio C Hamano | b4a9ede | 2009-04-08 07:36:32 | [diff] [blame] | 867 | --max-count=<number> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 868 | </dt> |
| 869 | <dd> |
| 870 | <p> |
Junio C Hamano | c5be4cc | 2011-03-09 07:20:43 | [diff] [blame] | 871 | Limit the number of commits to output. |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 872 | </p> |
| 873 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 874 | <dt class="hdlist1"> |
Junio C Hamano | b4a9ede | 2009-04-08 07:36:32 | [diff] [blame] | 875 | --skip=<number> |
Junio C Hamano | 17bbaca | 2006-12-25 11:36:31 | [diff] [blame] | 876 | </dt> |
| 877 | <dd> |
| 878 | <p> |
| 879 | Skip <em>number</em> commits before starting to show the commit output. |
| 880 | </p> |
| 881 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 882 | <dt class="hdlist1"> |
Junio C Hamano | b4a9ede | 2009-04-08 07:36:32 | [diff] [blame] | 883 | --since=<date> |
Junio C Hamano | eb41599 | 2008-06-08 22:49:47 | [diff] [blame] | 884 | </dt> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 885 | <dt class="hdlist1"> |
Junio C Hamano | b4a9ede | 2009-04-08 07:36:32 | [diff] [blame] | 886 | --after=<date> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 887 | </dt> |
| 888 | <dd> |
| 889 | <p> |
| 890 | Show commits more recent than a specific date. |
| 891 | </p> |
| 892 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 893 | <dt class="hdlist1"> |
Junio C Hamano | b4a9ede | 2009-04-08 07:36:32 | [diff] [blame] | 894 | --until=<date> |
Junio C Hamano | eb41599 | 2008-06-08 22:49:47 | [diff] [blame] | 895 | </dt> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 896 | <dt class="hdlist1"> |
Junio C Hamano | b4a9ede | 2009-04-08 07:36:32 | [diff] [blame] | 897 | --before=<date> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 898 | </dt> |
| 899 | <dd> |
| 900 | <p> |
| 901 | Show commits older than a specific date. |
| 902 | </p> |
| 903 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 904 | <dt class="hdlist1"> |
Junio C Hamano | b4a9ede | 2009-04-08 07:36:32 | [diff] [blame] | 905 | --max-age=<timestamp> |
Junio C Hamano | eb41599 | 2008-06-08 22:49:47 | [diff] [blame] | 906 | </dt> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 907 | <dt class="hdlist1"> |
Junio C Hamano | b4a9ede | 2009-04-08 07:36:32 | [diff] [blame] | 908 | --min-age=<timestamp> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 909 | </dt> |
| 910 | <dd> |
| 911 | <p> |
| 912 | Limit the commits output to specified time range. |
| 913 | </p> |
| 914 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 915 | <dt class="hdlist1"> |
Junio C Hamano | b4a9ede | 2009-04-08 07:36:32 | [diff] [blame] | 916 | --author=<pattern> |
Junio C Hamano | eb41599 | 2008-06-08 22:49:47 | [diff] [blame] | 917 | </dt> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 918 | <dt class="hdlist1"> |
Junio C Hamano | b4a9ede | 2009-04-08 07:36:32 | [diff] [blame] | 919 | --committer=<pattern> |
Junio C Hamano | 47c1e3c | 2006-09-25 04:45:55 | [diff] [blame] | 920 | </dt> |
| 921 | <dd> |
| 922 | <p> |
| 923 | Limit the commits output to ones with author/committer |
Junio C Hamano | 8ce35d7 | 2012-09-18 22:30:42 | [diff] [blame] | 924 | header lines that match the specified pattern (regular |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 925 | expression). With more than one <code>--author=<pattern></code>, |
Junio C Hamano | 8ce35d7 | 2012-09-18 22:30:42 | [diff] [blame] | 926 | commits whose author matches any of the given patterns are |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 927 | chosen (similarly for multiple <code>--committer=<pattern></code>). |
Junio C Hamano | 47c1e3c | 2006-09-25 04:45:55 | [diff] [blame] | 928 | </p> |
| 929 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 930 | <dt class="hdlist1"> |
Junio C Hamano | 9954ed7 | 2012-10-03 04:54:00 | [diff] [blame] | 931 | --grep-reflog=<pattern> |
| 932 | </dt> |
| 933 | <dd> |
| 934 | <p> |
| 935 | Limit the commits output to ones with reflog entries that |
| 936 | match the specified pattern (regular expression). With |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 937 | more than one <code>--grep-reflog</code>, commits whose reflog message |
Junio C Hamano | 9954ed7 | 2012-10-03 04:54:00 | [diff] [blame] | 938 | matches any of the given patterns are chosen. It is an |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 939 | error to use this option unless <code>--walk-reflogs</code> is in use. |
Junio C Hamano | 9954ed7 | 2012-10-03 04:54:00 | [diff] [blame] | 940 | </p> |
| 941 | </dd> |
| 942 | <dt class="hdlist1"> |
Junio C Hamano | b4a9ede | 2009-04-08 07:36:32 | [diff] [blame] | 943 | --grep=<pattern> |
Junio C Hamano | 47c1e3c | 2006-09-25 04:45:55 | [diff] [blame] | 944 | </dt> |
| 945 | <dd> |
| 946 | <p> |
| 947 | Limit the commits output to ones with log message that |
Junio C Hamano | 8ce35d7 | 2012-09-18 22:30:42 | [diff] [blame] | 948 | matches the specified pattern (regular expression). With |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 949 | more than one <code>--grep=<pattern></code>, commits whose message |
Junio C Hamano | 8ce35d7 | 2012-09-18 22:30:42 | [diff] [blame] | 950 | matches any of the given patterns are chosen (but see |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 951 | <code>--all-match</code>). |
Junio C Hamano | 47c1e3c | 2006-09-25 04:45:55 | [diff] [blame] | 952 | </p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 953 | <div class="paragraph"><p>When <code>--show-notes</code> is in effect, the message from the notes as |
Junio C Hamano | 9954ed7 | 2012-10-03 04:54:00 | [diff] [blame] | 954 | if it is part of the log message.</p></div> |
Junio C Hamano | 47c1e3c | 2006-09-25 04:45:55 | [diff] [blame] | 955 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 956 | <dt class="hdlist1"> |
Junio C Hamano | aa17c7c | 2008-11-03 04:36:58 | [diff] [blame] | 957 | --all-match |
| 958 | </dt> |
| 959 | <dd> |
| 960 | <p> |
| 961 | Limit the commits output to ones that match all given --grep, |
Junio C Hamano | 8ce35d7 | 2012-09-18 22:30:42 | [diff] [blame] | 962 | instead of ones that match at least one. |
Junio C Hamano | aa17c7c | 2008-11-03 04:36:58 | [diff] [blame] | 963 | </p> |
| 964 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 965 | <dt class="hdlist1"> |
Junio C Hamano | eb41599 | 2008-06-08 22:49:47 | [diff] [blame] | 966 | -i |
| 967 | </dt> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 968 | <dt class="hdlist1"> |
Junio C Hamano | eb41599 | 2008-06-08 22:49:47 | [diff] [blame] | 969 | --regexp-ignore-case |
Junio C Hamano | a5c02c5 | 2007-05-21 06:14:27 | [diff] [blame] | 970 | </dt> |
| 971 | <dd> |
| 972 | <p> |
| 973 | Match the regexp limiting patterns without regard to letters case. |
| 974 | </p> |
| 975 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 976 | <dt class="hdlist1"> |
Junio C Hamano | a129545 | 2012-11-13 22:32:04 | [diff] [blame] | 977 | --basic-regexp |
| 978 | </dt> |
| 979 | <dd> |
| 980 | <p> |
| 981 | Consider the limiting patterns to be basic regular expressions; |
| 982 | this is the default. |
| 983 | </p> |
| 984 | </dd> |
| 985 | <dt class="hdlist1"> |
Junio C Hamano | eb41599 | 2008-06-08 22:49:47 | [diff] [blame] | 986 | -E |
| 987 | </dt> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 988 | <dt class="hdlist1"> |
Junio C Hamano | eb41599 | 2008-06-08 22:49:47 | [diff] [blame] | 989 | --extended-regexp |
Junio C Hamano | a5c02c5 | 2007-05-21 06:14:27 | [diff] [blame] | 990 | </dt> |
| 991 | <dd> |
| 992 | <p> |
| 993 | Consider the limiting patterns to be extended regular expressions |
| 994 | instead of the default basic regular expressions. |
| 995 | </p> |
| 996 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 997 | <dt class="hdlist1"> |
Junio C Hamano | eb41599 | 2008-06-08 22:49:47 | [diff] [blame] | 998 | -F |
| 999 | </dt> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1000 | <dt class="hdlist1"> |
Junio C Hamano | eb41599 | 2008-06-08 22:49:47 | [diff] [blame] | 1001 | --fixed-strings |
Junio C Hamano | 24bc09a | 2008-02-28 00:27:44 | [diff] [blame] | 1002 | </dt> |
| 1003 | <dd> |
| 1004 | <p> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1005 | Consider the limiting patterns to be fixed strings (don’t interpret |
Junio C Hamano | 24bc09a | 2008-02-28 00:27:44 | [diff] [blame] | 1006 | pattern as a regular expression). |
| 1007 | </p> |
| 1008 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1009 | <dt class="hdlist1"> |
Junio C Hamano | a129545 | 2012-11-13 22:32:04 | [diff] [blame] | 1010 | --perl-regexp |
| 1011 | </dt> |
| 1012 | <dd> |
| 1013 | <p> |
| 1014 | Consider the limiting patterns to be Perl-compatible regexp. |
| 1015 | Requires libpcre to be compiled in. |
| 1016 | </p> |
| 1017 | </dd> |
| 1018 | <dt class="hdlist1"> |
Junio C Hamano | 9be1897 | 2006-01-28 08:54:57 | [diff] [blame] | 1019 | --remove-empty |
| 1020 | </dt> |
| 1021 | <dd> |
| 1022 | <p> |
| 1023 | Stop when a given path disappears from the tree. |
| 1024 | </p> |
| 1025 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1026 | <dt class="hdlist1"> |
Junio C Hamano | 934e178 | 2009-07-16 06:59:15 | [diff] [blame] | 1027 | --merges |
| 1028 | </dt> |
| 1029 | <dd> |
| 1030 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1031 | Print only merge commits. This is exactly the same as <code>--min-parents=2</code>. |
Junio C Hamano | 934e178 | 2009-07-16 06:59:15 | [diff] [blame] | 1032 | </p> |
| 1033 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1034 | <dt class="hdlist1"> |
Junio C Hamano | 7ccb9fd | 2006-07-15 01:38:40 | [diff] [blame] | 1035 | --no-merges |
| 1036 | </dt> |
| 1037 | <dd> |
| 1038 | <p> |
Junio C Hamano | f32ce26 | 2011-03-27 07:35:11 | [diff] [blame] | 1039 | Do not print commits with more than one parent. This is |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1040 | exactly the same as <code>--max-parents=1</code>. |
Junio C Hamano | 7ccb9fd | 2006-07-15 01:38:40 | [diff] [blame] | 1041 | </p> |
| 1042 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1043 | <dt class="hdlist1"> |
Junio C Hamano | f32ce26 | 2011-03-27 07:35:11 | [diff] [blame] | 1044 | --min-parents=<number> |
| 1045 | </dt> |
| 1046 | <dt class="hdlist1"> |
| 1047 | --max-parents=<number> |
| 1048 | </dt> |
| 1049 | <dt class="hdlist1"> |
| 1050 | --no-min-parents |
| 1051 | </dt> |
| 1052 | <dt class="hdlist1"> |
| 1053 | --no-max-parents |
| 1054 | </dt> |
| 1055 | <dd> |
| 1056 | <p> |
| 1057 | Show only commits which have at least (or at most) that many |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1058 | commits. In particular, <code>--max-parents=1</code> is the same as <code>--no-merges</code>, |
| 1059 | <code>--min-parents=2</code> is the same as <code>--merges</code>. <code>--max-parents=0</code> |
| 1060 | gives all root commits and <code>--min-parents=3</code> all octopus merges. |
Junio C Hamano | f32ce26 | 2011-03-27 07:35:11 | [diff] [blame] | 1061 | </p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1062 | <div class="paragraph"><p><code>--no-min-parents</code> and <code>--no-max-parents</code> reset these limits (to no limit) |
| 1063 | again. Equivalent forms are <code>--min-parents=0</code> (any commit has 0 or more |
| 1064 | parents) and <code>--max-parents=-1</code> (negative numbers denote no upper limit).</p></div> |
Junio C Hamano | f32ce26 | 2011-03-27 07:35:11 | [diff] [blame] | 1065 | </dd> |
| 1066 | <dt class="hdlist1"> |
Junio C Hamano | 554da79 | 2007-12-27 03:29:58 | [diff] [blame] | 1067 | --first-parent |
| 1068 | </dt> |
| 1069 | <dd> |
| 1070 | <p> |
| 1071 | Follow only the first parent commit upon seeing a merge |
| 1072 | commit. This option can give a better overview when |
| 1073 | viewing the evolution of a particular topic branch, |
| 1074 | because merges into a topic branch tend to be only about |
| 1075 | adjusting to updated upstream from time to time, and |
| 1076 | this option allows you to ignore the individual commits |
| 1077 | brought in to your history by such a merge. |
| 1078 | </p> |
| 1079 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1080 | <dt class="hdlist1"> |
Junio C Hamano | 872c568 | 2006-07-07 06:05:40 | [diff] [blame] | 1081 | --not |
| 1082 | </dt> |
| 1083 | <dd> |
| 1084 | <p> |
Junio C Hamano | 6926bef | 2007-06-16 09:54:05 | [diff] [blame] | 1085 | Reverses the meaning of the <em>^</em> prefix (or lack thereof) |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1086 | for all following revision specifiers, up to the next <em>--not</em>. |
Junio C Hamano | 872c568 | 2006-07-07 06:05:40 | [diff] [blame] | 1087 | </p> |
| 1088 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1089 | <dt class="hdlist1"> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 1090 | --all |
| 1091 | </dt> |
| 1092 | <dd> |
| 1093 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1094 | Pretend as if all the refs in <code>refs/</code> are listed on the |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1095 | command line as <em><commit></em>. |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 1096 | </p> |
| 1097 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1098 | <dt class="hdlist1"> |
Junio C Hamano | d2179ef | 2010-10-22 04:12:17 | [diff] [blame] | 1099 | --branches[=<pattern>] |
Junio C Hamano | 5081985 | 2008-11-19 02:07:56 | [diff] [blame] | 1100 | </dt> |
| 1101 | <dd> |
| 1102 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1103 | Pretend as if all the refs in <code>refs/heads</code> are listed |
Junio C Hamano | d2179ef | 2010-10-22 04:12:17 | [diff] [blame] | 1104 | on the command line as <em><commit></em>. If <em><pattern></em> is given, limit |
Junio C Hamano | 57827fb | 2010-01-23 03:02:50 | [diff] [blame] | 1105 | branches to ones matching given shell glob. If pattern lacks <em>?</em>, |
Junio C Hamano | 81d540a | 2012-03-02 19:52:47 | [diff] [blame] | 1106 | <em>*</em>, or <em>[</em>, <em>/*</em> at the end is implied. |
Junio C Hamano | 5081985 | 2008-11-19 02:07:56 | [diff] [blame] | 1107 | </p> |
| 1108 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1109 | <dt class="hdlist1"> |
Junio C Hamano | d2179ef | 2010-10-22 04:12:17 | [diff] [blame] | 1110 | --tags[=<pattern>] |
Junio C Hamano | 5081985 | 2008-11-19 02:07:56 | [diff] [blame] | 1111 | </dt> |
| 1112 | <dd> |
| 1113 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1114 | Pretend as if all the refs in <code>refs/tags</code> are listed |
Junio C Hamano | d2179ef | 2010-10-22 04:12:17 | [diff] [blame] | 1115 | on the command line as <em><commit></em>. If <em><pattern></em> is given, limit |
Junio C Hamano | 81d540a | 2012-03-02 19:52:47 | [diff] [blame] | 1116 | tags to ones matching given shell glob. If pattern lacks <em>?</em>, <em>*</em>, |
| 1117 | or <em>[</em>, <em>/*</em> at the end is implied. |
Junio C Hamano | 5081985 | 2008-11-19 02:07:56 | [diff] [blame] | 1118 | </p> |
| 1119 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1120 | <dt class="hdlist1"> |
Junio C Hamano | d2179ef | 2010-10-22 04:12:17 | [diff] [blame] | 1121 | --remotes[=<pattern>] |
Junio C Hamano | 5081985 | 2008-11-19 02:07:56 | [diff] [blame] | 1122 | </dt> |
| 1123 | <dd> |
| 1124 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1125 | Pretend as if all the refs in <code>refs/remotes</code> are listed |
Junio C Hamano | d2179ef | 2010-10-22 04:12:17 | [diff] [blame] | 1126 | on the command line as <em><commit></em>. If <em><pattern></em> is given, limit |
Junio C Hamano | 97bcb48 | 2010-11-25 03:16:07 | [diff] [blame] | 1127 | remote-tracking branches to ones matching given shell glob. |
Junio C Hamano | 81d540a | 2012-03-02 19:52:47 | [diff] [blame] | 1128 | If pattern lacks <em>?</em>, <em>*</em>, or <em>[</em>, <em>/*</em> at the end is implied. |
Junio C Hamano | 57827fb | 2010-01-23 03:02:50 | [diff] [blame] | 1129 | </p> |
| 1130 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1131 | <dt class="hdlist1"> |
Junio C Hamano | d2179ef | 2010-10-22 04:12:17 | [diff] [blame] | 1132 | --glob=<glob-pattern> |
Junio C Hamano | 57827fb | 2010-01-23 03:02:50 | [diff] [blame] | 1133 | </dt> |
| 1134 | <dd> |
| 1135 | <p> |
Junio C Hamano | d2179ef | 2010-10-22 04:12:17 | [diff] [blame] | 1136 | Pretend as if all the refs matching shell glob <em><glob-pattern></em> |
Junio C Hamano | 57827fb | 2010-01-23 03:02:50 | [diff] [blame] | 1137 | are listed on the command line as <em><commit></em>. Leading <em>refs/</em>, |
Junio C Hamano | 81d540a | 2012-03-02 19:52:47 | [diff] [blame] | 1138 | is automatically prepended if missing. If pattern lacks <em>?</em>, <em>*</em>, |
| 1139 | or <em>[</em>, <em>/*</em> at the end is implied. |
Junio C Hamano | 5081985 | 2008-11-19 02:07:56 | [diff] [blame] | 1140 | </p> |
| 1141 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1142 | <dt class="hdlist1"> |
Junio C Hamano | 084228c | 2011-05-30 08:13:52 | [diff] [blame] | 1143 | --ignore-missing |
| 1144 | </dt> |
| 1145 | <dd> |
| 1146 | <p> |
| 1147 | Upon seeing an invalid object name in the input, pretend as if |
| 1148 | the bad input was not given. |
| 1149 | </p> |
| 1150 | </dd> |
| 1151 | <dt class="hdlist1"> |
Junio C Hamano | c9245d9 | 2006-09-06 09:35:46 | [diff] [blame] | 1152 | --stdin |
| 1153 | </dt> |
| 1154 | <dd> |
| 1155 | <p> |
| 1156 | In addition to the <em><commit></em> listed on the command |
Junio C Hamano | 5706e0b | 2009-11-24 10:54:16 | [diff] [blame] | 1157 | line, read them from the standard input. If a <em>--</em> separator is |
| 1158 | seen, stop reading commits and start reading paths to limit the |
| 1159 | result. |
Junio C Hamano | c9245d9 | 2006-09-06 09:35:46 | [diff] [blame] | 1160 | </p> |
| 1161 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1162 | <dt class="hdlist1"> |
Junio C Hamano | 8c5802d | 2007-11-15 00:13:36 | [diff] [blame] | 1163 | --quiet |
| 1164 | </dt> |
| 1165 | <dd> |
| 1166 | <p> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1167 | Don’t print anything to standard output. This form |
Junio C Hamano | b0e0295 | 2008-01-19 08:02:00 | [diff] [blame] | 1168 | is primarily meant to allow the caller to |
Junio C Hamano | 8c5802d | 2007-11-15 00:13:36 | [diff] [blame] | 1169 | test the exit status to see if a range of objects is fully |
| 1170 | connected (or not). It is faster than redirecting stdout |
| 1171 | to /dev/null as the output does not have to be formatted. |
| 1172 | </p> |
| 1173 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1174 | <dt class="hdlist1"> |
Junio C Hamano | 9a2fb2d | 2011-03-23 05:40:15 | [diff] [blame] | 1175 | --cherry-mark |
| 1176 | </dt> |
| 1177 | <dd> |
| 1178 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1179 | Like <code>--cherry-pick</code> (see below) but mark equivalent commits |
| 1180 | with <code>=</code> rather than omitting them, and inequivalent ones with <code>+</code>. |
Junio C Hamano | 9a2fb2d | 2011-03-23 05:40:15 | [diff] [blame] | 1181 | </p> |
| 1182 | </dd> |
| 1183 | <dt class="hdlist1"> |
Junio C Hamano | d9e0e5d | 2007-04-14 16:22:04 | [diff] [blame] | 1184 | --cherry-pick |
| 1185 | </dt> |
| 1186 | <dd> |
| 1187 | <p> |
| 1188 | Omit any commit that introduces the same change as |
| 1189 | another commit on the "other side" when the set of |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1190 | commits are limited with symmetric difference. |
| 1191 | </p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1192 | <div class="paragraph"><p>For example, if you have two branches, <code>A</code> and <code>B</code>, a usual way |
Junio C Hamano | d9e0e5d | 2007-04-14 16:22:04 | [diff] [blame] | 1193 | to list all commits on only one side of them is with |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1194 | <code>--left-right</code> (see the example below in the description of |
| 1195 | the <code>--left-right</code> option). It however shows the commits that were cherry-picked |
Junio C Hamano | d9e0e5d | 2007-04-14 16:22:04 | [diff] [blame] | 1196 | from the other branch (for example, "3rd on b" may be cherry-picked |
| 1197 | from branch A). With this option, such pairs of commits are |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1198 | excluded from the output.</p></div> |
Junio C Hamano | d9e0e5d | 2007-04-14 16:22:04 | [diff] [blame] | 1199 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1200 | <dt class="hdlist1"> |
Junio C Hamano | 9a2fb2d | 2011-03-23 05:40:15 | [diff] [blame] | 1201 | --left-only |
| 1202 | </dt> |
| 1203 | <dt class="hdlist1"> |
| 1204 | --right-only |
| 1205 | </dt> |
| 1206 | <dd> |
| 1207 | <p> |
| 1208 | List only commits on the respective side of a symmetric range, |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1209 | i.e. only those which would be marked <code><</code> resp. <code>></code> by |
| 1210 | <code>--left-right</code>. |
Junio C Hamano | 9a2fb2d | 2011-03-23 05:40:15 | [diff] [blame] | 1211 | </p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1212 | <div class="paragraph"><p>For example, <code>--cherry-pick --right-only A...B</code> omits those |
| 1213 | commits from <code>B</code> which are in <code>A</code> or are patch-equivalent to a commit in |
| 1214 | <code>A</code>. In other words, this lists the <code>+</code> commits from <code>git cherry A B</code>. |
| 1215 | More precisely, <code>--cherry-pick --right-only --no-merges</code> gives the exact |
Junio C Hamano | 9a2fb2d | 2011-03-23 05:40:15 | [diff] [blame] | 1216 | list.</p></div> |
| 1217 | </dd> |
| 1218 | <dt class="hdlist1"> |
| 1219 | --cherry |
| 1220 | </dt> |
| 1221 | <dd> |
| 1222 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1223 | A synonym for <code>--right-only --cherry-mark --no-merges</code>; useful to |
Junio C Hamano | 9a2fb2d | 2011-03-23 05:40:15 | [diff] [blame] | 1224 | limit the output to the commits on our side and mark those that |
| 1225 | have been applied to the other side of a forked history with |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1226 | <code>git log --cherry upstream...mybranch</code>, similar to |
| 1227 | <code>git cherry upstream mybranch</code>. |
Junio C Hamano | 9a2fb2d | 2011-03-23 05:40:15 | [diff] [blame] | 1228 | </p> |
| 1229 | </dd> |
| 1230 | <dt class="hdlist1"> |
Junio C Hamano | eb41599 | 2008-06-08 22:49:47 | [diff] [blame] | 1231 | -g |
| 1232 | </dt> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1233 | <dt class="hdlist1"> |
Junio C Hamano | eb41599 | 2008-06-08 22:49:47 | [diff] [blame] | 1234 | --walk-reflogs |
Junio C Hamano | db450ba | 2007-01-21 08:57:14 | [diff] [blame] | 1235 | </dt> |
| 1236 | <dd> |
| 1237 | <p> |
| 1238 | Instead of walking the commit ancestry chain, walk |
| 1239 | reflog entries from the most recent one to older ones. |
| 1240 | When this option is used you cannot specify commits to |
Junio C Hamano | 6926bef | 2007-06-16 09:54:05 | [diff] [blame] | 1241 | exclude (that is, <em>^commit</em>, <em>commit1..commit2</em>, |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1242 | nor <em>commit1...commit2</em> notations cannot be used). |
| 1243 | </p> |
| 1244 | <div class="paragraph"><p>With <em>--pretty</em> format other than oneline (for obvious reasons), |
Junio C Hamano | db450ba | 2007-01-21 08:57:14 | [diff] [blame] | 1245 | this causes the output to have two extra lines of information |
Junio C Hamano | 1d90cb0 | 2007-07-03 07:05:31 | [diff] [blame] | 1246 | taken from the reflog. By default, <em>commit@{Nth}</em> notation is |
Junio C Hamano | db450ba | 2007-01-21 08:57:14 | [diff] [blame] | 1247 | used in the output. When the starting commit is specified as |
Junio C Hamano | 1d36888 | 2008-08-11 22:03:10 | [diff] [blame] | 1248 | <em>commit@{now}</em>, output also uses <em>commit@{timestamp}</em> notation |
Junio C Hamano | db450ba | 2007-01-21 08:57:14 | [diff] [blame] | 1249 | instead. Under <em>--pretty=oneline</em>, the commit message is |
Junio C Hamano | bdebabb | 2007-08-23 00:25:09 | [diff] [blame] | 1250 | prefixed with this information on the same line. |
Junio C Hamano | 1d36888 | 2008-08-11 22:03:10 | [diff] [blame] | 1251 | This option cannot be combined with <em>--reverse</em>. |
Junio C Hamano | a28a920 | 2012-06-21 07:08:23 | [diff] [blame] | 1252 | See also <a href="git-reflog.html">git-reflog(1)</a>.</p></div> |
Junio C Hamano | db450ba | 2007-01-21 08:57:14 | [diff] [blame] | 1253 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1254 | <dt class="hdlist1"> |
Junio C Hamano | 859f3b4 | 2006-08-04 10:04:30 | [diff] [blame] | 1255 | --merge |
| 1256 | </dt> |
| 1257 | <dd> |
| 1258 | <p> |
| 1259 | After a failed merge, show refs that touch files having a |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1260 | conflict and don’t exist on all heads to merge. |
Junio C Hamano | 859f3b4 | 2006-08-04 10:04:30 | [diff] [blame] | 1261 | </p> |
| 1262 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1263 | <dt class="hdlist1"> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1264 | --boundary |
Junio C Hamano | a0778c9 | 2006-08-29 04:03:11 | [diff] [blame] | 1265 | </dt> |
| 1266 | <dd> |
| 1267 | <p> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1268 | Output uninteresting commits at the boundary, which are usually |
| 1269 | not shown. |
| 1270 | </p> |
| 1271 | </dd> |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1272 | </dl></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1273 | </div></div> |
| 1274 | </div> |
| 1275 | <div class="sect2"> |
| 1276 | <h3 id="_history_simplification">History Simplification</h3> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1277 | <div class="paragraph"><p>Sometimes you are only interested in parts of the history, for example the |
Junio C Hamano | 2836349 | 2008-11-14 08:26:31 | [diff] [blame] | 1278 | commits modifying a particular <path>. But there are two parts of |
| 1279 | <em>History Simplification</em>, one part is selecting the commits and the other |
| 1280 | is how to do it, as there are various strategies to simplify the history.</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1281 | <div class="paragraph"><p>The following options select the commits to be shown:</p></div> |
| 1282 | <div class="dlist"><dl> |
| 1283 | <dt class="hdlist1"> |
Junio C Hamano | 2836349 | 2008-11-14 08:26:31 | [diff] [blame] | 1284 | <paths> |
| 1285 | </dt> |
| 1286 | <dd> |
| 1287 | <p> |
| 1288 | Commits modifying the given <paths> are selected. |
| 1289 | </p> |
| 1290 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1291 | <dt class="hdlist1"> |
Junio C Hamano | 2836349 | 2008-11-14 08:26:31 | [diff] [blame] | 1292 | --simplify-by-decoration |
| 1293 | </dt> |
| 1294 | <dd> |
| 1295 | <p> |
| 1296 | Commits that are referred by some branch or tag are selected. |
| 1297 | </p> |
| 1298 | </dd> |
| 1299 | </dl></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1300 | <div class="paragraph"><p>Note that extra commits can be shown to give a meaningful history.</p></div> |
| 1301 | <div class="paragraph"><p>The following options affect the way the simplification is performed:</p></div> |
| 1302 | <div class="dlist"><dl> |
| 1303 | <dt class="hdlist1"> |
Junio C Hamano | 2836349 | 2008-11-14 08:26:31 | [diff] [blame] | 1304 | Default mode |
| 1305 | </dt> |
| 1306 | <dd> |
| 1307 | <p> |
| 1308 | Simplifies the history to the simplest history explaining the |
| 1309 | final state of the tree. Simplest because it prunes some side |
| 1310 | branches if the end result is the same (i.e. merging branches |
| 1311 | with the same content) |
| 1312 | </p> |
| 1313 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1314 | <dt class="hdlist1"> |
Junio C Hamano | 2836349 | 2008-11-14 08:26:31 | [diff] [blame] | 1315 | --full-history |
| 1316 | </dt> |
| 1317 | <dd> |
| 1318 | <p> |
Junio C Hamano | 15567bc | 2011-07-23 00:51:59 | [diff] [blame] | 1319 | Same as the default mode, but does not prune some history. |
Junio C Hamano | 2836349 | 2008-11-14 08:26:31 | [diff] [blame] | 1320 | </p> |
| 1321 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1322 | <dt class="hdlist1"> |
Junio C Hamano | 2836349 | 2008-11-14 08:26:31 | [diff] [blame] | 1323 | --dense |
| 1324 | </dt> |
| 1325 | <dd> |
| 1326 | <p> |
| 1327 | Only the selected commits are shown, plus some to have a |
| 1328 | meaningful history. |
| 1329 | </p> |
| 1330 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1331 | <dt class="hdlist1"> |
Junio C Hamano | 2836349 | 2008-11-14 08:26:31 | [diff] [blame] | 1332 | --sparse |
| 1333 | </dt> |
| 1334 | <dd> |
| 1335 | <p> |
| 1336 | All commits in the simplified history are shown. |
| 1337 | </p> |
| 1338 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1339 | <dt class="hdlist1"> |
Junio C Hamano | 2836349 | 2008-11-14 08:26:31 | [diff] [blame] | 1340 | --simplify-merges |
| 1341 | </dt> |
| 1342 | <dd> |
| 1343 | <p> |
| 1344 | Additional option to <em>--full-history</em> to remove some needless |
| 1345 | merges from the resulting history, as there are no selected |
| 1346 | commits contributing to this merge. |
| 1347 | </p> |
| 1348 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1349 | <dt class="hdlist1"> |
Junio C Hamano | 89a5734 | 2010-06-22 23:22:55 | [diff] [blame] | 1350 | --ancestry-path |
| 1351 | </dt> |
| 1352 | <dd> |
| 1353 | <p> |
| 1354 | When given a range of commits to display (e.g. <em>commit1..commit2</em> |
| 1355 | or <em>commit2 ^commit1</em>), only display commits that exist |
| 1356 | directly on the ancestry chain between the <em>commit1</em> and |
| 1357 | <em>commit2</em>, i.e. commits that are both descendants of <em>commit1</em>, |
| 1358 | and ancestors of <em>commit2</em>. |
| 1359 | </p> |
| 1360 | </dd> |
Junio C Hamano | 2836349 | 2008-11-14 08:26:31 | [diff] [blame] | 1361 | </dl></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1362 | <div class="paragraph"><p>A more detailed explanation follows.</p></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1363 | <div class="paragraph"><p>Suppose you specified <code>foo</code> as the <paths>. We shall call commits |
| 1364 | that modify <code>foo</code> !TREESAME, and the rest TREESAME. (In a diff |
| 1365 | filtered for <code>foo</code>, they look different and equal, respectively.)</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1366 | <div class="paragraph"><p>In the following, we will always refer to the same example history to |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1367 | illustrate the differences between simplification settings. We assume |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1368 | that you are filtering for a file <code>foo</code> in this commit graph:</p></div> |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1369 | <div class="listingblock"> |
| 1370 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1371 | <pre><code> .-A---M---N---O---P |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1372 | / / / / / |
| 1373 | I B C D E |
| 1374 | \ / / / / |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1375 | `-------------'</code></pre> |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1376 | </div></div> |
Junio C Hamano | 360e3a1 | 2011-07-13 23:51:56 | [diff] [blame] | 1377 | <div class="paragraph"><p>The horizontal line of history A---P is taken to be the first parent of |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1378 | each merge. The commits are:</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1379 | <div class="ulist"><ul> |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1380 | <li> |
| 1381 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1382 | <code>I</code> is the initial commit, in which <code>foo</code> exists with contents |
| 1383 | "asdf", and a file <code>quux</code> exists with contents "quux". Initial |
| 1384 | commits are compared to an empty tree, so <code>I</code> is !TREESAME. |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1385 | </p> |
| 1386 | </li> |
| 1387 | <li> |
| 1388 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1389 | In <code>A</code>, <code>foo</code> contains just "foo". |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1390 | </p> |
| 1391 | </li> |
| 1392 | <li> |
| 1393 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1394 | <code>B</code> contains the same change as <code>A</code>. Its merge <code>M</code> is trivial and |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1395 | hence TREESAME to all parents. |
| 1396 | </p> |
| 1397 | </li> |
| 1398 | <li> |
| 1399 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1400 | <code>C</code> does not change <code>foo</code>, but its merge <code>N</code> changes it to "foobar", |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1401 | so it is not TREESAME to any parent. |
| 1402 | </p> |
| 1403 | </li> |
| 1404 | <li> |
| 1405 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1406 | <code>D</code> sets <code>foo</code> to "baz". Its merge <code>O</code> combines the strings from |
| 1407 | <code>N</code> and <code>D</code> to "foobarbaz"; i.e., it is not TREESAME to any parent. |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1408 | </p> |
| 1409 | </li> |
| 1410 | <li> |
| 1411 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1412 | <code>E</code> changes <code>quux</code> to "xyzzy", and its merge <code>P</code> combines the |
| 1413 | strings to "quux xyzzy". Despite appearing interesting, <code>P</code> is |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1414 | TREESAME to all parents. |
| 1415 | </p> |
| 1416 | </li> |
| 1417 | </ul></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1418 | <div class="paragraph"><p><em>rev-list</em> walks backwards through history, including or excluding |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1419 | commits based on whether <em>--full-history</em> and/or parent rewriting |
| 1420 | (via <em>--parents</em> or <em>--children</em>) are used. The following settings |
| 1421 | are available.</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1422 | <div class="dlist"><dl> |
| 1423 | <dt class="hdlist1"> |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1424 | Default mode |
| 1425 | </dt> |
| 1426 | <dd> |
| 1427 | <p> |
| 1428 | Commits are included if they are not TREESAME to any parent |
| 1429 | (though this can be changed, see <em>--sparse</em> below). If the |
| 1430 | commit was a merge, and it was TREESAME to one parent, follow |
| 1431 | only that parent. (Even if there are several TREESAME |
| 1432 | parents, follow only one of them.) Otherwise, follow all |
| 1433 | parents. |
| 1434 | </p> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1435 | <div class="paragraph"><p>This results in:</p></div> |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1436 | <div class="listingblock"> |
| 1437 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1438 | <pre><code> .-A---N---O |
Junio C Hamano | 89a5734 | 2010-06-22 23:22:55 | [diff] [blame] | 1439 | / / / |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1440 | I---------D</code></pre> |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1441 | </div></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1442 | <div class="paragraph"><p>Note how the rule to only follow the TREESAME parent, if one is |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1443 | available, removed <code>B</code> from consideration entirely. <code>C</code> was |
| 1444 | considered via <code>N</code>, but is TREESAME. Root commits are compared to an |
| 1445 | empty tree, so <code>I</code> is !TREESAME.</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1446 | <div class="paragraph"><p>Parent/child relations are only visible with --parents, but that does |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1447 | not affect the commits selected in default mode, so we have shown the |
| 1448 | parent lines.</p></div> |
| 1449 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1450 | <dt class="hdlist1"> |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1451 | --full-history without parent rewriting |
| 1452 | </dt> |
| 1453 | <dd> |
| 1454 | <p> |
| 1455 | This mode differs from the default in one point: always follow |
| 1456 | all parents of a merge, even if it is TREESAME to one of them. |
| 1457 | Even if more than one side of the merge has commits that are |
| 1458 | included, this does not imply that the merge itself is! In |
| 1459 | the example, we get |
| 1460 | </p> |
| 1461 | <div class="listingblock"> |
| 1462 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1463 | <pre><code> I A B N D O</code></pre> |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1464 | </div></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1465 | <div class="paragraph"><p><code>P</code> and <code>M</code> were excluded because they are TREESAME to a parent. <code>E</code>, |
| 1466 | <code>C</code> and <code>B</code> were all walked, but only <code>B</code> was !TREESAME, so the others |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1467 | do not appear.</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1468 | <div class="paragraph"><p>Note that without parent rewriting, it is not really possible to talk |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1469 | about the parent/child relationships between the commits, so we show |
| 1470 | them disconnected.</p></div> |
| 1471 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1472 | <dt class="hdlist1"> |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1473 | --full-history with parent rewriting |
| 1474 | </dt> |
| 1475 | <dd> |
| 1476 | <p> |
| 1477 | Ordinary commits are only included if they are !TREESAME |
| 1478 | (though this can be changed, see <em>--sparse</em> below). |
| 1479 | </p> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1480 | <div class="paragraph"><p>Merges are always included. However, their parent list is rewritten: |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1481 | Along each parent, prune away commits that are not included |
| 1482 | themselves. This results in</p></div> |
| 1483 | <div class="listingblock"> |
| 1484 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1485 | <pre><code> .-A---M---N---O---P |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1486 | / / / / / |
| 1487 | I B / D / |
| 1488 | \ / / / / |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1489 | `-------------'</code></pre> |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1490 | </div></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1491 | <div class="paragraph"><p>Compare to <em>--full-history</em> without rewriting above. Note that <code>E</code> |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1492 | was pruned away because it is TREESAME, but the parent list of P was |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1493 | rewritten to contain <code>E</code>'s parent <code>I</code>. The same happened for <code>C</code> and |
| 1494 | <code>N</code>. Note also that <code>P</code> was included despite being TREESAME.</p></div> |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1495 | </dd> |
| 1496 | </dl></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1497 | <div class="paragraph"><p>In addition to the above settings, you can change whether TREESAME |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1498 | affects inclusion:</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1499 | <div class="dlist"><dl> |
| 1500 | <dt class="hdlist1"> |
Junio C Hamano | eb41599 | 2008-06-08 22:49:47 | [diff] [blame] | 1501 | --dense |
| 1502 | </dt> |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1503 | <dd> |
| 1504 | <p> |
| 1505 | Commits that are walked are included if they are not TREESAME |
| 1506 | to any parent. |
| 1507 | </p> |
| 1508 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1509 | <dt class="hdlist1"> |
Junio C Hamano | eb41599 | 2008-06-08 22:49:47 | [diff] [blame] | 1510 | --sparse |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1511 | </dt> |
| 1512 | <dd> |
| 1513 | <p> |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1514 | All commits that are walked are included. |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1515 | </p> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1516 | <div class="paragraph"><p>Note that without <em>--full-history</em>, this still simplifies merges: if |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1517 | one of the parents is TREESAME, we follow only that one, so the other |
| 1518 | sides of the merge are never walked.</p></div> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1519 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1520 | <dt class="hdlist1"> |
Junio C Hamano | a2f4662 | 2008-09-03 05:20:31 | [diff] [blame] | 1521 | --simplify-merges |
| 1522 | </dt> |
| 1523 | <dd> |
| 1524 | <p> |
| 1525 | First, build a history graph in the same way that |
| 1526 | <em>--full-history</em> with parent rewriting does (see above). |
| 1527 | </p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1528 | <div class="paragraph"><p>Then simplify each commit <code>C</code> to its replacement <code>C'</code> in the final |
Junio C Hamano | a2f4662 | 2008-09-03 05:20:31 | [diff] [blame] | 1529 | history according to the following rules:</p></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1530 | <div class="openblock"> |
| 1531 | <div class="content"> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1532 | <div class="ulist"><ul> |
Junio C Hamano | a2f4662 | 2008-09-03 05:20:31 | [diff] [blame] | 1533 | <li> |
| 1534 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1535 | Set <code>C'</code> to <code>C</code>. |
Junio C Hamano | a2f4662 | 2008-09-03 05:20:31 | [diff] [blame] | 1536 | </p> |
| 1537 | </li> |
| 1538 | <li> |
| 1539 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1540 | Replace each parent <code>P</code> of <code>C'</code> with its simplification <code>P'</code>. In |
Junio C Hamano | a2f4662 | 2008-09-03 05:20:31 | [diff] [blame] | 1541 | the process, drop parents that are ancestors of other parents, and |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1542 | remove duplicates. |
Junio C Hamano | a2f4662 | 2008-09-03 05:20:31 | [diff] [blame] | 1543 | </p> |
| 1544 | </li> |
| 1545 | <li> |
| 1546 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1547 | If after this parent rewriting, <code>C'</code> is a root or merge commit (has |
Junio C Hamano | a2f4662 | 2008-09-03 05:20:31 | [diff] [blame] | 1548 | zero or >1 parents), a boundary commit, or !TREESAME, it remains. |
| 1549 | Otherwise, it is replaced with its only parent. |
| 1550 | </p> |
| 1551 | </li> |
| 1552 | </ul></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1553 | </div></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1554 | <div class="paragraph"><p>The effect of this is best shown by way of comparing to |
Junio C Hamano | a2f4662 | 2008-09-03 05:20:31 | [diff] [blame] | 1555 | <em>--full-history</em> with parent rewriting. The example turns into:</p></div> |
| 1556 | <div class="listingblock"> |
| 1557 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1558 | <pre><code> .-A---M---N---O |
Junio C Hamano | a2f4662 | 2008-09-03 05:20:31 | [diff] [blame] | 1559 | / / / |
| 1560 | I B D |
| 1561 | \ / / |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1562 | `---------'</code></pre> |
Junio C Hamano | a2f4662 | 2008-09-03 05:20:31 | [diff] [blame] | 1563 | </div></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1564 | <div class="paragraph"><p>Note the major differences in <code>N</code> and <code>P</code> over <em>--full-history</em>:</p></div> |
| 1565 | <div class="openblock"> |
| 1566 | <div class="content"> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1567 | <div class="ulist"><ul> |
Junio C Hamano | a2f4662 | 2008-09-03 05:20:31 | [diff] [blame] | 1568 | <li> |
| 1569 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1570 | <code>N</code>'s parent list had <code>I</code> removed, because it is an ancestor of the |
| 1571 | other parent <code>M</code>. Still, <code>N</code> remained because it is !TREESAME. |
Junio C Hamano | a2f4662 | 2008-09-03 05:20:31 | [diff] [blame] | 1572 | </p> |
| 1573 | </li> |
| 1574 | <li> |
| 1575 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1576 | <code>P</code>'s parent list similarly had <code>I</code> removed. <code>P</code> was then |
Junio C Hamano | a2f4662 | 2008-09-03 05:20:31 | [diff] [blame] | 1577 | removed completely, because it had one parent and is TREESAME. |
| 1578 | </p> |
| 1579 | </li> |
| 1580 | </ul></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1581 | </div></div> |
Junio C Hamano | a2f4662 | 2008-09-03 05:20:31 | [diff] [blame] | 1582 | </dd> |
| 1583 | </dl></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1584 | <div class="paragraph"><p>Finally, there is a fifth simplification mode available:</p></div> |
| 1585 | <div class="dlist"><dl> |
| 1586 | <dt class="hdlist1"> |
Junio C Hamano | 89a5734 | 2010-06-22 23:22:55 | [diff] [blame] | 1587 | --ancestry-path |
| 1588 | </dt> |
| 1589 | <dd> |
| 1590 | <p> |
| 1591 | Limit the displayed commits to those directly on the ancestry |
| 1592 | chain between the "from" and "to" commits in the given commit |
| 1593 | range. I.e. only display commits that are ancestor of the "to" |
| 1594 | commit, and descendants of the "from" commit. |
| 1595 | </p> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1596 | <div class="paragraph"><p>As an example use case, consider the following commit history:</p></div> |
Junio C Hamano | 89a5734 | 2010-06-22 23:22:55 | [diff] [blame] | 1597 | <div class="listingblock"> |
| 1598 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1599 | <pre><code> D---E-------F |
Junio C Hamano | 89a5734 | 2010-06-22 23:22:55 | [diff] [blame] | 1600 | / \ \ |
| 1601 | B---C---G---H---I---J |
| 1602 | / \ |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1603 | A-------K---------------L--M</code></pre> |
Junio C Hamano | 89a5734 | 2010-06-22 23:22:55 | [diff] [blame] | 1604 | </div></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1605 | <div class="paragraph"><p>A regular <em>D..M</em> computes the set of commits that are ancestors of <code>M</code>, |
| 1606 | but excludes the ones that are ancestors of <code>D</code>. This is useful to see |
| 1607 | what happened to the history leading to <code>M</code> since <code>D</code>, in the sense |
| 1608 | that "what does <code>M</code> have that did not exist in <code>D</code>". The result in this |
| 1609 | example would be all the commits, except <code>A</code> and <code>B</code> (and <code>D</code> itself, |
Junio C Hamano | 89a5734 | 2010-06-22 23:22:55 | [diff] [blame] | 1610 | of course).</p></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1611 | <div class="paragraph"><p>When we want to find out what commits in <code>M</code> are contaminated with the |
| 1612 | bug introduced by <code>D</code> and need fixing, however, we might want to view |
| 1613 | only the subset of <em>D..M</em> that are actually descendants of <code>D</code>, i.e. |
| 1614 | excluding <code>C</code> and <code>K</code>. This is exactly what the <em>--ancestry-path</em> |
Junio C Hamano | 89a5734 | 2010-06-22 23:22:55 | [diff] [blame] | 1615 | option does. Applied to the <em>D..M</em> range, it results in:</p></div> |
| 1616 | <div class="listingblock"> |
| 1617 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1618 | <pre><code> E-------F |
Junio C Hamano | 89a5734 | 2010-06-22 23:22:55 | [diff] [blame] | 1619 | \ \ |
| 1620 | G---H---I---J |
| 1621 | \ |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1622 | L--M</code></pre> |
Junio C Hamano | 89a5734 | 2010-06-22 23:22:55 | [diff] [blame] | 1623 | </div></div> |
| 1624 | </dd> |
| 1625 | </dl></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1626 | <div class="paragraph"><p>The <em>--simplify-by-decoration</em> option allows you to view only the |
Junio C Hamano | 2836349 | 2008-11-14 08:26:31 | [diff] [blame] | 1627 | big picture of the topology of the history, by omitting commits |
| 1628 | that are not referenced by tags. Commits are marked as !TREESAME |
| 1629 | (in other words, kept after history simplification rules described |
| 1630 | above) if (1) they are referenced by tags, or (2) they change the |
| 1631 | contents of the paths given on the command line. All other |
| 1632 | commits are marked as TREESAME (subject to be simplified away).</p></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1633 | </div> |
| 1634 | <div class="sect2"> |
| 1635 | <h3 id="_bisection_helpers">Bisection Helpers</h3> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1636 | <div class="dlist"><dl> |
| 1637 | <dt class="hdlist1"> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1638 | --bisect |
| 1639 | </dt> |
| 1640 | <dd> |
| 1641 | <p> |
| 1642 | Limit output to the one commit object which is roughly halfway between |
Junio C Hamano | 5706e0b | 2009-11-24 10:54:16 | [diff] [blame] | 1643 | included and excluded commits. Note that the bad bisection ref |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1644 | <code>refs/bisect/bad</code> is added to the included commits (if it |
| 1645 | exists) and the good bisection refs <code>refs/bisect/good-*</code> are |
Junio C Hamano | 5706e0b | 2009-11-24 10:54:16 | [diff] [blame] | 1646 | added to the excluded commits (if they exist). Thus, supposing there |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1647 | are no refs in <code>refs/bisect/</code>, if |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1648 | </p> |
Junio C Hamano | a76cb0d | 2008-08-13 20:04:10 | [diff] [blame] | 1649 | </dd> |
| 1650 | </dl></div> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1651 | <div class="listingblock"> |
| 1652 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1653 | <pre><code> $ git rev-list --bisect foo ^bar ^baz</code></pre> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1654 | </div></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1655 | <div class="paragraph"><p>outputs <em>midpoint</em>, the output of the two commands</p></div> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1656 | <div class="listingblock"> |
| 1657 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1658 | <pre><code> $ git rev-list foo ^midpoint |
| 1659 | $ git rev-list midpoint ^bar ^baz</code></pre> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1660 | </div></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1661 | <div class="paragraph"><p>would be of roughly the same length. Finding the change which |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1662 | introduces a regression is thus reduced to a binary search: repeatedly |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1663 | generate and test new 'midpoint’s until the commit chain is of length |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 1664 | one.</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1665 | <div class="dlist"><dl> |
| 1666 | <dt class="hdlist1"> |
Junio C Hamano | 20f64da | 2007-04-04 18:38:30 | [diff] [blame] | 1667 | --bisect-vars |
| 1668 | </dt> |
| 1669 | <dd> |
| 1670 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1671 | This calculates the same as <code>--bisect</code>, except that refs in |
| 1672 | <code>refs/bisect/</code> are not used, and except that this outputs |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1673 | text ready to be eval’ed by the shell. These lines will assign the |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1674 | name of the midpoint revision to the variable <code>bisect_rev</code>, and the |
| 1675 | expected number of commits to be tested after <code>bisect_rev</code> is tested |
| 1676 | to <code>bisect_nr</code>, the expected number of commits to be tested if |
| 1677 | <code>bisect_rev</code> turns out to be good to <code>bisect_good</code>, the expected |
| 1678 | number of commits to be tested if <code>bisect_rev</code> turns out to be bad to |
| 1679 | <code>bisect_bad</code>, and the number of commits we are bisecting right now to |
| 1680 | <code>bisect_all</code>. |
Junio C Hamano | 20f64da | 2007-04-04 18:38:30 | [diff] [blame] | 1681 | </p> |
| 1682 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1683 | <dt class="hdlist1"> |
Junio C Hamano | 1974bf2 | 2007-10-31 05:57:20 | [diff] [blame] | 1684 | --bisect-all |
| 1685 | </dt> |
| 1686 | <dd> |
| 1687 | <p> |
| 1688 | This outputs all the commit objects between the included and excluded |
| 1689 | commits, ordered by their distance to the included and excluded |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1690 | commits. Refs in <code>refs/bisect/</code> are not used. The farthest |
Junio C Hamano | 5706e0b | 2009-11-24 10:54:16 | [diff] [blame] | 1691 | from them is displayed first. (This is the only one displayed by |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1692 | <code>--bisect</code>.) |
Junio C Hamano | 1974bf2 | 2007-10-31 05:57:20 | [diff] [blame] | 1693 | </p> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1694 | <div class="paragraph"><p>This is useful because it makes it easy to choose a good commit to |
Junio C Hamano | 1974bf2 | 2007-10-31 05:57:20 | [diff] [blame] | 1695 | test when you want to avoid to test some of them for some reason (they |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 1696 | may not compile for example).</p></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1697 | <div class="paragraph"><p>This option can be used along with <code>--bisect-vars</code>, in this case, |
Junio C Hamano | 1974bf2 | 2007-10-31 05:57:20 | [diff] [blame] | 1698 | after all the sorted commit objects, there will be the same text as if |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1699 | <code>--bisect-vars</code> had been used alone.</p></div> |
Junio C Hamano | 792c5a9 | 2009-03-08 08:45:13 | [diff] [blame] | 1700 | </dd> |
| 1701 | </dl></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1702 | </div> |
| 1703 | <div class="sect2"> |
| 1704 | <h3 id="_commit_ordering">Commit Ordering</h3> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1705 | <div class="paragraph"><p>By default, the commits are shown in reverse chronological order.</p></div> |
| 1706 | <div class="dlist"><dl> |
| 1707 | <dt class="hdlist1"> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1708 | --date-order |
| 1709 | </dt> |
| 1710 | <dd> |
| 1711 | <p> |
Junio C Hamano | d031611 | 2012-08-22 19:55:29 | [diff] [blame] | 1712 | Show no parents before all of its children are shown, but |
| 1713 | otherwise show commits in the commit timestamp order. |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1714 | </p> |
| 1715 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1716 | <dt class="hdlist1"> |
Junio C Hamano | d031611 | 2012-08-22 19:55:29 | [diff] [blame] | 1717 | --topo-order |
| 1718 | </dt> |
| 1719 | <dd> |
| 1720 | <p> |
| 1721 | Show no parents before all of its children are shown, and |
| 1722 | avoid showing commits on multiple lines of history |
| 1723 | intermixed. |
| 1724 | </p> |
| 1725 | <div class="paragraph"><p>For example, in a commit history like this:</p></div> |
| 1726 | <div class="listingblock"> |
| 1727 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1728 | <pre><code> ---1----2----4----7 |
Junio C Hamano | d031611 | 2012-08-22 19:55:29 | [diff] [blame] | 1729 | \ \ |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1730 | 3----5----6----8---</code></pre> |
Junio C Hamano | d031611 | 2012-08-22 19:55:29 | [diff] [blame] | 1731 | </div></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1732 | <div class="paragraph"><p>where the numbers denote the order of commit timestamps, <code>git |
| 1733 | rev-list</code> and friends with <code>--date-order</code> show the commits in the |
Junio C Hamano | d031611 | 2012-08-22 19:55:29 | [diff] [blame] | 1734 | timestamp order: 8 7 6 5 4 3 2 1.</p></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1735 | <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 |
Junio C Hamano | d031611 | 2012-08-22 19:55:29 | [diff] [blame] | 1736 | 3 1); some older commits are shown before newer ones in order to |
| 1737 | avoid showing the commits from two parallel development track mixed |
| 1738 | together.</p></div> |
| 1739 | </dd> |
| 1740 | <dt class="hdlist1"> |
Junio C Hamano | 053827f | 2007-02-14 07:23:58 | [diff] [blame] | 1741 | --reverse |
| 1742 | </dt> |
| 1743 | <dd> |
| 1744 | <p> |
| 1745 | Output the commits in reverse order. |
Junio C Hamano | bdebabb | 2007-08-23 00:25:09 | [diff] [blame] | 1746 | Cannot be combined with <em>--walk-reflogs</em>. |
Junio C Hamano | 053827f | 2007-02-14 07:23:58 | [diff] [blame] | 1747 | </p> |
| 1748 | </dd> |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 1749 | </dl></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1750 | </div> |
| 1751 | <div class="sect2"> |
| 1752 | <h3 id="_object_traversal">Object Traversal</h3> |
Junio C Hamano | 076ffcc | 2013-02-06 05:13:21 | [diff] [blame] | 1753 | <div class="paragraph"><p>These options are mostly targeted for packing of Git repositories.</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1754 | <div class="dlist"><dl> |
| 1755 | <dt class="hdlist1"> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1756 | --objects |
| 1757 | </dt> |
| 1758 | <dd> |
| 1759 | <p> |
| 1760 | Print the object IDs of any object referenced by the listed |
Junio C Hamano | b0e0295 | 2008-01-19 08:02:00 | [diff] [blame] | 1761 | commits. <em>--objects foo ^bar</em> thus means "send me |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1762 | all object IDs which I need to download if I have the commit |
| 1763 | object <em>bar</em>, but not <em>foo</em>". |
| 1764 | </p> |
| 1765 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1766 | <dt class="hdlist1"> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1767 | --objects-edge |
| 1768 | </dt> |
| 1769 | <dd> |
| 1770 | <p> |
| 1771 | Similar to <em>--objects</em>, but also print the IDs of excluded |
| 1772 | commits prefixed with a "-" character. This is used by |
Junio C Hamano | a28a920 | 2012-06-21 07:08:23 | [diff] [blame] | 1773 | <a href="git-pack-objects.html">git-pack-objects(1)</a> to build "thin" pack, which records |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1774 | objects in deltified form based on objects contained in these |
| 1775 | excluded commits to reduce network traffic. |
| 1776 | </p> |
| 1777 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1778 | <dt class="hdlist1"> |
Junio C Hamano | 89e135d | 2006-09-03 06:18:25 | [diff] [blame] | 1779 | --unpacked |
| 1780 | </dt> |
| 1781 | <dd> |
| 1782 | <p> |
| 1783 | Only useful with <em>--objects</em>; print the object IDs that are not |
| 1784 | in packs. |
Junio C Hamano | a0778c9 | 2006-08-29 04:03:11 | [diff] [blame] | 1785 | </p> |
| 1786 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1787 | <dt class="hdlist1"> |
Junio C Hamano | eccdd4a | 2012-09-10 23:28:17 | [diff] [blame] | 1788 | --no-walk[=(sorted|unsorted)] |
Junio C Hamano | a196f6d | 2007-07-24 08:10:27 | [diff] [blame] | 1789 | </dt> |
| 1790 | <dd> |
| 1791 | <p> |
Junio C Hamano | eccdd4a | 2012-09-10 23:28:17 | [diff] [blame] | 1792 | Only show the given commits, but do not traverse their ancestors. |
| 1793 | This has no effect if a range is specified. If the argument |
| 1794 | "unsorted" is given, the commits are show in the order they were |
| 1795 | given on the command line. Otherwise (if "sorted" or no argument |
| 1796 | was given), the commits are show in reverse chronological order |
| 1797 | by commit time. |
Junio C Hamano | a196f6d | 2007-07-24 08:10:27 | [diff] [blame] | 1798 | </p> |
| 1799 | </dd> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 1800 | <dt class="hdlist1"> |
Junio C Hamano | a196f6d | 2007-07-24 08:10:27 | [diff] [blame] | 1801 | --do-walk |
| 1802 | </dt> |
| 1803 | <dd> |
| 1804 | <p> |
| 1805 | Overrides a previous --no-walk. |
| 1806 | </p> |
| 1807 | </dd> |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 1808 | </dl></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1809 | </div> |
| 1810 | <div class="sect2"> |
| 1811 | <h3 id="_commit_formatting">Commit Formatting</h3> |
Junio C Hamano | a28a920 | 2012-06-21 07:08:23 | [diff] [blame] | 1812 | <div class="paragraph"><p>Using these options, <a href="git-rev-list.html">git-rev-list(1)</a> will act similar to the |
| 1813 | more specialized family of commit log tools: <a href="git-log.html">git-log(1)</a>, |
| 1814 | <a href="git-show.html">git-show(1)</a>, and <a href="git-whatchanged.html">git-whatchanged(1)</a></p></div> |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 1815 | <div class="dlist"><dl> |
| 1816 | <dt class="hdlist1"> |
| 1817 | --pretty[=<format>] |
| 1818 | </dt> |
| 1819 | <dt class="hdlist1"> |
| 1820 | --format=<format> |
| 1821 | </dt> |
| 1822 | <dd> |
| 1823 | <p> |
| 1824 | Pretty-print the contents of the commit logs in a given format, |
| 1825 | where <em><format></em> can be one of <em>oneline</em>, <em>short</em>, <em>medium</em>, |
| 1826 | <em>full</em>, <em>fuller</em>, <em>email</em>, <em>raw</em> and <em>format:<string></em>. See |
| 1827 | the "PRETTY FORMATS" section for some additional details for each |
| 1828 | format. When omitted, the format defaults to <em>medium</em>. |
| 1829 | </p> |
| 1830 | <div class="paragraph"><p>Note: you can specify the default pretty format in the repository |
Junio C Hamano | a28a920 | 2012-06-21 07:08:23 | [diff] [blame] | 1831 | configuration (see <a href="git-config.html">git-config(1)</a>).</p></div> |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 1832 | </dd> |
| 1833 | <dt class="hdlist1"> |
| 1834 | --abbrev-commit |
| 1835 | </dt> |
| 1836 | <dd> |
| 1837 | <p> |
| 1838 | Instead of showing the full 40-byte hexadecimal commit object |
| 1839 | name, show only a partial prefix. Non default number of |
| 1840 | digits can be specified with "--abbrev=<n>" (which also modifies |
| 1841 | diff output, if it is displayed). |
| 1842 | </p> |
| 1843 | <div class="paragraph"><p>This should make "--pretty=oneline" a whole lot more readable for |
| 1844 | people using 80-column terminals.</p></div> |
| 1845 | </dd> |
| 1846 | <dt class="hdlist1"> |
Junio C Hamano | f93530e | 2011-05-25 23:59:59 | [diff] [blame] | 1847 | --no-abbrev-commit |
| 1848 | </dt> |
| 1849 | <dd> |
| 1850 | <p> |
| 1851 | Show the full 40-byte hexadecimal commit object name. This negates |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1852 | <code>--abbrev-commit</code> and those options which imply it such as |
Junio C Hamano | f93530e | 2011-05-25 23:59:59 | [diff] [blame] | 1853 | "--oneline". It also overrides the <em>log.abbrevCommit</em> variable. |
| 1854 | </p> |
| 1855 | </dd> |
| 1856 | <dt class="hdlist1"> |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 1857 | --oneline |
| 1858 | </dt> |
| 1859 | <dd> |
| 1860 | <p> |
| 1861 | This is a shorthand for "--pretty=oneline --abbrev-commit" |
| 1862 | used together. |
| 1863 | </p> |
| 1864 | </dd> |
| 1865 | <dt class="hdlist1"> |
| 1866 | --encoding[=<encoding>] |
| 1867 | </dt> |
| 1868 | <dd> |
| 1869 | <p> |
| 1870 | The commit objects record the encoding used for the log message |
| 1871 | in their encoding header; this option can be used to tell the |
| 1872 | command to re-code the commit log message in the encoding |
| 1873 | preferred by the user. For non plumbing commands this |
| 1874 | defaults to UTF-8. |
| 1875 | </p> |
| 1876 | </dd> |
| 1877 | <dt class="hdlist1"> |
Junio C Hamano | 6003346 | 2011-05-03 00:48:43 | [diff] [blame] | 1878 | --notes[=<ref>] |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 1879 | </dt> |
| 1880 | <dd> |
| 1881 | <p> |
Junio C Hamano | a28a920 | 2012-06-21 07:08:23 | [diff] [blame] | 1882 | Show the notes (see <a href="git-notes.html">git-notes(1)</a>) that annotate the |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 1883 | commit, when showing the commit log message. This is the default |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1884 | for <code>git log</code>, <code>git show</code> and <code>git whatchanged</code> commands when |
| 1885 | there is no <code>--pretty</code>, <code>--format</code> nor <code>--oneline</code> option given |
Junio C Hamano | 6003346 | 2011-05-03 00:48:43 | [diff] [blame] | 1886 | on the command line. |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 1887 | </p> |
Junio C Hamano | 6003346 | 2011-05-03 00:48:43 | [diff] [blame] | 1888 | <div class="paragraph"><p>By default, the notes shown are from the notes refs listed in the |
| 1889 | <em>core.notesRef</em> and <em>notes.displayRef</em> variables (or corresponding |
Junio C Hamano | a28a920 | 2012-06-21 07:08:23 | [diff] [blame] | 1890 | environment overrides). See <a href="git-config.html">git-config(1)</a> for more details.</p></div> |
Junio C Hamano | 6003346 | 2011-05-03 00:48:43 | [diff] [blame] | 1891 | <div class="paragraph"><p>With an optional <em><ref></em> argument, show this notes ref instead of the |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1892 | default notes ref(s). The ref is taken to be in <code>refs/notes/</code> if it |
Junio C Hamano | 6003346 | 2011-05-03 00:48:43 | [diff] [blame] | 1893 | is not qualified.</p></div> |
| 1894 | <div class="paragraph"><p>Multiple --notes options can be combined to control which notes are |
| 1895 | being displayed. Examples: "--notes=foo" will show only notes from |
| 1896 | "refs/notes/foo"; "--notes=foo --notes" will show both notes from |
| 1897 | "refs/notes/foo" and from the default notes ref(s).</p></div> |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 1898 | </dd> |
| 1899 | <dt class="hdlist1"> |
Junio C Hamano | 6003346 | 2011-05-03 00:48:43 | [diff] [blame] | 1900 | --no-notes |
| 1901 | </dt> |
| 1902 | <dd> |
| 1903 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1904 | Do not show notes. This negates the above <code>--notes</code> option, by |
Junio C Hamano | 6003346 | 2011-05-03 00:48:43 | [diff] [blame] | 1905 | resetting the list of notes refs from which notes are shown. |
| 1906 | Options are parsed in the order given on the command line, so e.g. |
| 1907 | "--notes --notes=foo --no-notes --notes=bar" will only show notes |
| 1908 | from "refs/notes/bar". |
| 1909 | </p> |
| 1910 | </dd> |
| 1911 | <dt class="hdlist1"> |
| 1912 | --show-notes[=<ref>] |
| 1913 | </dt> |
| 1914 | <dt class="hdlist1"> |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 1915 | --[no-]standard-notes |
| 1916 | </dt> |
| 1917 | <dd> |
| 1918 | <p> |
Junio C Hamano | 6003346 | 2011-05-03 00:48:43 | [diff] [blame] | 1919 | These options are deprecated. Use the above --notes/--no-notes |
| 1920 | options instead. |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 1921 | </p> |
| 1922 | </dd> |
| 1923 | <dt class="hdlist1"> |
Junio C Hamano | 0acb1ae | 2012-09-24 21:28:13 | [diff] [blame] | 1924 | --show-signature |
| 1925 | </dt> |
| 1926 | <dd> |
| 1927 | <p> |
| 1928 | Check the validity of a signed commit object by passing the signature |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1929 | to <code>gpg --verify</code> and show the output. |
Junio C Hamano | 0acb1ae | 2012-09-24 21:28:13 | [diff] [blame] | 1930 | </p> |
| 1931 | </dd> |
| 1932 | <dt class="hdlist1"> |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 1933 | --relative-date |
| 1934 | </dt> |
| 1935 | <dd> |
| 1936 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1937 | Synonym for <code>--date=relative</code>. |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 1938 | </p> |
| 1939 | </dd> |
| 1940 | <dt class="hdlist1"> |
| 1941 | --date=(relative|local|default|iso|rfc|short|raw) |
| 1942 | </dt> |
| 1943 | <dd> |
| 1944 | <p> |
| 1945 | Only takes effect for dates shown in human-readable format, such |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1946 | as when using "--pretty". <code>log.date</code> config variable sets a default |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 1947 | value for log command’s --date option. |
| 1948 | </p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1949 | <div class="paragraph"><p><code>--date=relative</code> shows dates relative to the current time, |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 1950 | e.g. "2 hours ago".</p></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1951 | <div class="paragraph"><p><code>--date=local</code> shows timestamps in user’s local timezone.</p></div> |
| 1952 | <div class="paragraph"><p><code>--date=iso</code> (or <code>--date=iso8601</code>) shows timestamps in ISO 8601 format.</p></div> |
| 1953 | <div class="paragraph"><p><code>--date=rfc</code> (or <code>--date=rfc2822</code>) shows timestamps in RFC 2822 |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 1954 | format, often found in E-mail messages.</p></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1955 | <div class="paragraph"><p><code>--date=short</code> shows only date but not time, in <code>YYYY-MM-DD</code> format.</p></div> |
Junio C Hamano | 076ffcc | 2013-02-06 05:13:21 | [diff] [blame] | 1956 | <div class="paragraph"><p><code>--date=raw</code> shows the date in the internal raw Git format <code>%s %z</code> format.</p></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 1957 | <div class="paragraph"><p><code>--date=default</code> shows timestamps in the original timezone |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 1958 | (either committer’s or author’s).</p></div> |
| 1959 | </dd> |
| 1960 | <dt class="hdlist1"> |
| 1961 | --header |
| 1962 | </dt> |
| 1963 | <dd> |
| 1964 | <p> |
| 1965 | Print the contents of the commit in raw-format; each record is |
| 1966 | separated with a NUL character. |
| 1967 | </p> |
| 1968 | </dd> |
| 1969 | <dt class="hdlist1"> |
| 1970 | --parents |
| 1971 | </dt> |
| 1972 | <dd> |
| 1973 | <p> |
| 1974 | Print also the parents of the commit (in the form "commit parent…"). |
| 1975 | Also enables parent rewriting, see <em>History Simplification</em> below. |
| 1976 | </p> |
| 1977 | </dd> |
| 1978 | <dt class="hdlist1"> |
| 1979 | --children |
| 1980 | </dt> |
| 1981 | <dd> |
| 1982 | <p> |
| 1983 | Print also the children of the commit (in the form "commit child…"). |
| 1984 | Also enables parent rewriting, see <em>History Simplification</em> below. |
| 1985 | </p> |
| 1986 | </dd> |
| 1987 | <dt class="hdlist1"> |
| 1988 | --timestamp |
| 1989 | </dt> |
| 1990 | <dd> |
| 1991 | <p> |
| 1992 | Print the raw commit timestamp. |
| 1993 | </p> |
| 1994 | </dd> |
| 1995 | <dt class="hdlist1"> |
| 1996 | --left-right |
| 1997 | </dt> |
| 1998 | <dd> |
| 1999 | <p> |
| 2000 | Mark which side of a symmetric diff a commit is reachable from. |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2001 | Commits from the left side are prefixed with <code><</code> and those from |
| 2002 | the right with <code>></code>. If combined with <code>--boundary</code>, those |
| 2003 | commits are prefixed with <code>-</code>. |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 2004 | </p> |
| 2005 | <div class="paragraph"><p>For example, if you have this topology:</p></div> |
| 2006 | <div class="listingblock"> |
| 2007 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2008 | <pre><code> y---b---b branch B |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 2009 | / \ / |
| 2010 | / . |
| 2011 | / / \ |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2012 | o---x---a---a branch A</code></pre> |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 2013 | </div></div> |
| 2014 | <div class="paragraph"><p>you would get an output like this:</p></div> |
| 2015 | <div class="listingblock"> |
| 2016 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2017 | <pre><code> $ git rev-list --left-right --boundary --pretty=oneline A...B |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 2018 | |
| 2019 | >bbbbbbb... 3rd on b |
| 2020 | >bbbbbbb... 2nd on b |
| 2021 | <aaaaaaa... 3rd on a |
| 2022 | <aaaaaaa... 2nd on a |
| 2023 | -yyyyyyy... 1st on b |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2024 | -xxxxxxx... 1st on a</code></pre> |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 2025 | </div></div> |
| 2026 | </dd> |
| 2027 | <dt class="hdlist1"> |
| 2028 | --graph |
| 2029 | </dt> |
| 2030 | <dd> |
| 2031 | <p> |
| 2032 | Draw a text-based graphical representation of the commit history |
| 2033 | on the left hand side of the output. This may cause extra lines |
| 2034 | to be printed in between commits, in order for the graph history |
| 2035 | to be drawn properly. |
| 2036 | </p> |
| 2037 | <div class="paragraph"><p>This enables parent rewriting, see <em>History Simplification</em> below.</p></div> |
| 2038 | <div class="paragraph"><p>This implies the <em>--topo-order</em> option by default, but the |
| 2039 | <em>--date-order</em> option may also be specified.</p></div> |
| 2040 | </dd> |
| 2041 | <dt class="hdlist1"> |
| 2042 | --count |
| 2043 | </dt> |
| 2044 | <dd> |
| 2045 | <p> |
| 2046 | Print a number stating how many commits would have been |
| 2047 | listed, and suppress all other output. When used together |
| 2048 | with <em>--left-right</em>, instead print the counts for left and |
Junio C Hamano | b77f819 | 2011-05-05 01:30:38 | [diff] [blame] | 2049 | right commits, separated by a tab. When used together with |
| 2050 | <em>--cherry-mark</em>, omit patch equivalent commits from these |
| 2051 | counts and print the count for equivalent commits separated |
| 2052 | by a tab. |
Junio C Hamano | d2c978f | 2011-03-20 19:42:22 | [diff] [blame] | 2053 | </p> |
| 2054 | </dd> |
| 2055 | </dl></div> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 2056 | </div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2057 | </div> |
| 2058 | </div> |
| 2059 | <div class="sect1"> |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 2060 | <h2 id="_pretty_formats">PRETTY FORMATS</h2> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2061 | <div class="sectionbody"> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 2062 | <div class="paragraph"><p>If the commit is a merge, and if the pretty-format |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2063 | is not <em>oneline</em>, <em>email</em> or <em>raw</em>, an additional line is |
| 2064 | inserted before the <em>Author:</em> line. This line begins with |
| 2065 | "Merge: " and the sha1s of ancestral commits are printed, |
| 2066 | separated by spaces. Note that the listed commits may not |
| 2067 | necessarily be the list of the <strong>direct</strong> parent commits if you |
| 2068 | have limited your view of history: for example, if you are |
| 2069 | only interested in changes related to a certain directory or |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 2070 | file.</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 2071 | <div class="paragraph"><p>There are several built-in formats, and you can define |
Junio C Hamano | a574a09 | 2010-06-13 19:57:10 | [diff] [blame] | 2072 | additional formats by setting a pretty.<name> |
| 2073 | config option to either another format name, or a |
| 2074 | <em>format:</em> string, as described below (see |
Junio C Hamano | a28a920 | 2012-06-21 07:08:23 | [diff] [blame] | 2075 | <a href="git-config.html">git-config(1)</a>). Here are the details of the |
Junio C Hamano | a574a09 | 2010-06-13 19:57:10 | [diff] [blame] | 2076 | built-in formats:</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 2077 | <div class="ulist"><ul> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2078 | <li> |
| 2079 | <p> |
| 2080 | <em>oneline</em> |
| 2081 | </p> |
| 2082 | <div class="literalblock"> |
| 2083 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2084 | <pre><code><sha1> <title line></code></pre> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2085 | </div></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 2086 | <div class="paragraph"><p>This is designed to be as compact as possible.</p></div> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2087 | </li> |
| 2088 | <li> |
| 2089 | <p> |
| 2090 | <em>short</em> |
| 2091 | </p> |
| 2092 | <div class="literalblock"> |
| 2093 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2094 | <pre><code>commit <sha1> |
| 2095 | Author: <author></code></pre> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2096 | </div></div> |
| 2097 | <div class="literalblock"> |
| 2098 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2099 | <pre><code><title line></code></pre> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2100 | </div></div> |
| 2101 | </li> |
| 2102 | <li> |
| 2103 | <p> |
| 2104 | <em>medium</em> |
| 2105 | </p> |
| 2106 | <div class="literalblock"> |
| 2107 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2108 | <pre><code>commit <sha1> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2109 | Author: <author> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2110 | Date: <author date></code></pre> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2111 | </div></div> |
| 2112 | <div class="literalblock"> |
| 2113 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2114 | <pre><code><title line></code></pre> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2115 | </div></div> |
| 2116 | <div class="literalblock"> |
| 2117 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2118 | <pre><code><full commit message></code></pre> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2119 | </div></div> |
| 2120 | </li> |
| 2121 | <li> |
| 2122 | <p> |
| 2123 | <em>full</em> |
| 2124 | </p> |
| 2125 | <div class="literalblock"> |
| 2126 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2127 | <pre><code>commit <sha1> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2128 | Author: <author> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2129 | Commit: <committer></code></pre> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2130 | </div></div> |
| 2131 | <div class="literalblock"> |
| 2132 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2133 | <pre><code><title line></code></pre> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2134 | </div></div> |
| 2135 | <div class="literalblock"> |
| 2136 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2137 | <pre><code><full commit message></code></pre> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2138 | </div></div> |
| 2139 | </li> |
| 2140 | <li> |
| 2141 | <p> |
| 2142 | <em>fuller</em> |
| 2143 | </p> |
| 2144 | <div class="literalblock"> |
| 2145 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2146 | <pre><code>commit <sha1> |
Junio C Hamano | 6a3c827 | 2008-12-19 21:38:18 | [diff] [blame] | 2147 | Author: <author> |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 2148 | AuthorDate: <author date> |
Junio C Hamano | 6a3c827 | 2008-12-19 21:38:18 | [diff] [blame] | 2149 | Commit: <committer> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2150 | CommitDate: <committer date></code></pre> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2151 | </div></div> |
| 2152 | <div class="literalblock"> |
| 2153 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2154 | <pre><code><title line></code></pre> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2155 | </div></div> |
| 2156 | <div class="literalblock"> |
| 2157 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2158 | <pre><code><full commit message></code></pre> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2159 | </div></div> |
| 2160 | </li> |
| 2161 | <li> |
| 2162 | <p> |
| 2163 | <em>email</em> |
| 2164 | </p> |
| 2165 | <div class="literalblock"> |
| 2166 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2167 | <pre><code>From <sha1> <date> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2168 | From: <author> |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 2169 | Date: <author date> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2170 | Subject: [PATCH] <title line></code></pre> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2171 | </div></div> |
| 2172 | <div class="literalblock"> |
| 2173 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2174 | <pre><code><full commit message></code></pre> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2175 | </div></div> |
| 2176 | </li> |
| 2177 | <li> |
| 2178 | <p> |
| 2179 | <em>raw</em> |
| 2180 | </p> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 2181 | <div class="paragraph"><p>The <em>raw</em> format shows the entire commit exactly as |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2182 | stored in the commit object. Notably, the SHA1s are |
| 2183 | displayed in full, regardless of whether --abbrev or |
| 2184 | --no-abbrev are used, and <em>parents</em> information show the |
| 2185 | true parent commits, without taking grafts nor history |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 2186 | simplification into account.</p></div> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2187 | </li> |
| 2188 | <li> |
| 2189 | <p> |
Junio C Hamano | e32ec8b | 2010-06-02 23:32:31 | [diff] [blame] | 2190 | <em>format:<string></em> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2191 | </p> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 2192 | <div class="paragraph"><p>The <em>format:<string></em> format allows you to specify which information |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2193 | you want to show. It works a little bit like printf format, |
| 2194 | with the notable exception that you get a newline with <em>%n</em> |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 2195 | instead of <em>\n</em>.</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 2196 | <div class="paragraph"><p>E.g, <em>format:"The author of %h was %an, %ar%nThe title was >>%s<<%n"</em> |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 2197 | would show something like this:</p></div> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2198 | <div class="listingblock"> |
| 2199 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2200 | <pre><code>The author of fe6e0ee was Junio C Hamano, 23 hours ago |
| 2201 | The title was >>t4119: test autocomputing -p<n> for traditional diff input.<<</code></pre> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2202 | </div></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 2203 | <div class="paragraph"><p>The placeholders are:</p></div> |
| 2204 | <div class="ulist"><ul> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2205 | <li> |
| 2206 | <p> |
| 2207 | <em>%H</em>: commit hash |
| 2208 | </p> |
| 2209 | </li> |
| 2210 | <li> |
| 2211 | <p> |
| 2212 | <em>%h</em>: abbreviated commit hash |
| 2213 | </p> |
| 2214 | </li> |
| 2215 | <li> |
| 2216 | <p> |
| 2217 | <em>%T</em>: tree hash |
| 2218 | </p> |
| 2219 | </li> |
| 2220 | <li> |
| 2221 | <p> |
| 2222 | <em>%t</em>: abbreviated tree hash |
| 2223 | </p> |
| 2224 | </li> |
| 2225 | <li> |
| 2226 | <p> |
| 2227 | <em>%P</em>: parent hashes |
| 2228 | </p> |
| 2229 | </li> |
| 2230 | <li> |
| 2231 | <p> |
| 2232 | <em>%p</em>: abbreviated parent hashes |
| 2233 | </p> |
| 2234 | </li> |
| 2235 | <li> |
| 2236 | <p> |
| 2237 | <em>%an</em>: author name |
| 2238 | </p> |
| 2239 | </li> |
| 2240 | <li> |
| 2241 | <p> |
Junio C Hamano | a28a920 | 2012-06-21 07:08:23 | [diff] [blame] | 2242 | <em>%aN</em>: author name (respecting .mailmap, see <a href="git-shortlog.html">git-shortlog(1)</a> or <a href="git-blame.html">git-blame(1)</a>) |
Junio C Hamano | f5a9362 | 2008-07-16 03:23:57 | [diff] [blame] | 2243 | </p> |
| 2244 | </li> |
| 2245 | <li> |
| 2246 | <p> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2247 | <em>%ae</em>: author email |
| 2248 | </p> |
| 2249 | </li> |
| 2250 | <li> |
| 2251 | <p> |
Junio C Hamano | a28a920 | 2012-06-21 07:08:23 | [diff] [blame] | 2252 | <em>%aE</em>: author email (respecting .mailmap, see <a href="git-shortlog.html">git-shortlog(1)</a> or <a href="git-blame.html">git-blame(1)</a>) |
Junio C Hamano | 8bc410e | 2009-02-15 10:38:19 | [diff] [blame] | 2253 | </p> |
| 2254 | </li> |
| 2255 | <li> |
| 2256 | <p> |
Junio C Hamano | a387df3 | 2008-08-29 08:56:58 | [diff] [blame] | 2257 | <em>%ad</em>: author date (format respects --date= option) |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2258 | </p> |
| 2259 | </li> |
| 2260 | <li> |
| 2261 | <p> |
| 2262 | <em>%aD</em>: author date, RFC2822 style |
| 2263 | </p> |
| 2264 | </li> |
| 2265 | <li> |
| 2266 | <p> |
| 2267 | <em>%ar</em>: author date, relative |
| 2268 | </p> |
| 2269 | </li> |
| 2270 | <li> |
| 2271 | <p> |
| 2272 | <em>%at</em>: author date, UNIX timestamp |
| 2273 | </p> |
| 2274 | </li> |
| 2275 | <li> |
| 2276 | <p> |
Junio C Hamano | 02f130b | 2007-07-14 08:26:56 | [diff] [blame] | 2277 | <em>%ai</em>: author date, ISO 8601 format |
| 2278 | </p> |
| 2279 | </li> |
| 2280 | <li> |
| 2281 | <p> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2282 | <em>%cn</em>: committer name |
| 2283 | </p> |
| 2284 | </li> |
| 2285 | <li> |
| 2286 | <p> |
Junio C Hamano | a28a920 | 2012-06-21 07:08:23 | [diff] [blame] | 2287 | <em>%cN</em>: committer name (respecting .mailmap, see <a href="git-shortlog.html">git-shortlog(1)</a> or <a href="git-blame.html">git-blame(1)</a>) |
Junio C Hamano | f5a9362 | 2008-07-16 03:23:57 | [diff] [blame] | 2288 | </p> |
| 2289 | </li> |
| 2290 | <li> |
| 2291 | <p> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2292 | <em>%ce</em>: committer email |
| 2293 | </p> |
| 2294 | </li> |
| 2295 | <li> |
| 2296 | <p> |
Junio C Hamano | a28a920 | 2012-06-21 07:08:23 | [diff] [blame] | 2297 | <em>%cE</em>: committer email (respecting .mailmap, see <a href="git-shortlog.html">git-shortlog(1)</a> or <a href="git-blame.html">git-blame(1)</a>) |
Junio C Hamano | 8bc410e | 2009-02-15 10:38:19 | [diff] [blame] | 2298 | </p> |
| 2299 | </li> |
| 2300 | <li> |
| 2301 | <p> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2302 | <em>%cd</em>: committer date |
| 2303 | </p> |
| 2304 | </li> |
| 2305 | <li> |
| 2306 | <p> |
| 2307 | <em>%cD</em>: committer date, RFC2822 style |
| 2308 | </p> |
| 2309 | </li> |
| 2310 | <li> |
| 2311 | <p> |
| 2312 | <em>%cr</em>: committer date, relative |
| 2313 | </p> |
| 2314 | </li> |
| 2315 | <li> |
| 2316 | <p> |
| 2317 | <em>%ct</em>: committer date, UNIX timestamp |
| 2318 | </p> |
| 2319 | </li> |
| 2320 | <li> |
| 2321 | <p> |
Junio C Hamano | 02f130b | 2007-07-14 08:26:56 | [diff] [blame] | 2322 | <em>%ci</em>: committer date, ISO 8601 format |
| 2323 | </p> |
| 2324 | </li> |
| 2325 | <li> |
| 2326 | <p> |
Junio C Hamano | a28a920 | 2012-06-21 07:08:23 | [diff] [blame] | 2327 | <em>%d</em>: ref names, like the --decorate option of <a href="git-log.html">git-log(1)</a> |
Junio C Hamano | 5e4d8de | 2008-09-19 06:27:02 | [diff] [blame] | 2328 | </p> |
| 2329 | </li> |
| 2330 | <li> |
| 2331 | <p> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2332 | <em>%e</em>: encoding |
| 2333 | </p> |
| 2334 | </li> |
| 2335 | <li> |
| 2336 | <p> |
| 2337 | <em>%s</em>: subject |
| 2338 | </p> |
| 2339 | </li> |
| 2340 | <li> |
| 2341 | <p> |
Junio C Hamano | 5f9a6f0 | 2009-04-06 08:26:56 | [diff] [blame] | 2342 | <em>%f</em>: sanitized subject line, suitable for a filename |
| 2343 | </p> |
| 2344 | </li> |
| 2345 | <li> |
| 2346 | <p> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2347 | <em>%b</em>: body |
| 2348 | </p> |
| 2349 | </li> |
| 2350 | <li> |
| 2351 | <p> |
Junio C Hamano | cb39aea | 2010-05-09 07:24:48 | [diff] [blame] | 2352 | <em>%B</em>: raw body (unwrapped subject and body) |
| 2353 | </p> |
| 2354 | </li> |
| 2355 | <li> |
| 2356 | <p> |
Junio C Hamano | 3b70d3c | 2009-11-21 17:37:37 | [diff] [blame] | 2357 | <em>%N</em>: commit notes |
| 2358 | </p> |
| 2359 | </li> |
| 2360 | <li> |
| 2361 | <p> |
Junio C Hamano | 0acb1ae | 2012-09-24 21:28:13 | [diff] [blame] | 2362 | <em>%GG</em>: raw verification message from GPG for a signed commit |
| 2363 | </p> |
| 2364 | </li> |
| 2365 | <li> |
| 2366 | <p> |
| 2367 | <em>%G?</em>: show either "G" for Good or "B" for Bad for a signed commit |
| 2368 | </p> |
| 2369 | </li> |
| 2370 | <li> |
| 2371 | <p> |
| 2372 | <em>%GS</em>: show the name of the signer for a signed commit |
| 2373 | </p> |
| 2374 | </li> |
| 2375 | <li> |
| 2376 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2377 | <em>%gD</em>: reflog selector, e.g., <code>refs/stash@{1}</code> |
Junio C Hamano | c21ab05 | 2009-10-31 04:03:55 | [diff] [blame] | 2378 | </p> |
| 2379 | </li> |
| 2380 | <li> |
| 2381 | <p> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2382 | <em>%gd</em>: shortened reflog selector, e.g., <code>stash@{1}</code> |
Junio C Hamano | c21ab05 | 2009-10-31 04:03:55 | [diff] [blame] | 2383 | </p> |
| 2384 | </li> |
| 2385 | <li> |
| 2386 | <p> |
Junio C Hamano | 962f3a3 | 2011-12-22 20:21:44 | [diff] [blame] | 2387 | <em>%gn</em>: reflog identity name |
| 2388 | </p> |
| 2389 | </li> |
| 2390 | <li> |
| 2391 | <p> |
Junio C Hamano | a28a920 | 2012-06-21 07:08:23 | [diff] [blame] | 2392 | <em>%gN</em>: reflog identity name (respecting .mailmap, see <a href="git-shortlog.html">git-shortlog(1)</a> or <a href="git-blame.html">git-blame(1)</a>) |
Junio C Hamano | 962f3a3 | 2011-12-22 20:21:44 | [diff] [blame] | 2393 | </p> |
| 2394 | </li> |
| 2395 | <li> |
| 2396 | <p> |
| 2397 | <em>%ge</em>: reflog identity email |
| 2398 | </p> |
| 2399 | </li> |
| 2400 | <li> |
| 2401 | <p> |
Junio C Hamano | a28a920 | 2012-06-21 07:08:23 | [diff] [blame] | 2402 | <em>%gE</em>: reflog identity email (respecting .mailmap, see <a href="git-shortlog.html">git-shortlog(1)</a> or <a href="git-blame.html">git-blame(1)</a>) |
Junio C Hamano | 962f3a3 | 2011-12-22 20:21:44 | [diff] [blame] | 2403 | </p> |
| 2404 | </li> |
| 2405 | <li> |
| 2406 | <p> |
Junio C Hamano | c21ab05 | 2009-10-31 04:03:55 | [diff] [blame] | 2407 | <em>%gs</em>: reflog subject |
| 2408 | </p> |
| 2409 | </li> |
| 2410 | <li> |
| 2411 | <p> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2412 | <em>%Cred</em>: switch color to red |
| 2413 | </p> |
| 2414 | </li> |
| 2415 | <li> |
| 2416 | <p> |
| 2417 | <em>%Cgreen</em>: switch color to green |
| 2418 | </p> |
| 2419 | </li> |
| 2420 | <li> |
| 2421 | <p> |
| 2422 | <em>%Cblue</em>: switch color to blue |
| 2423 | </p> |
| 2424 | </li> |
| 2425 | <li> |
| 2426 | <p> |
| 2427 | <em>%Creset</em>: reset color |
| 2428 | </p> |
| 2429 | </li> |
| 2430 | <li> |
| 2431 | <p> |
Junio C Hamano | abad6da | 2013-01-06 09:06:32 | [diff] [blame] | 2432 | <em>%C(…)</em>: color specification, as described in color.branch.* config option; |
| 2433 | adding <code>auto,</code> at the beginning will emit color only when colors are |
| 2434 | enabled for log output (by <code>color.diff</code>, <code>color.ui</code>, or <code>--color</code>, and |
| 2435 | respecting the <code>auto</code> settings of the former if we are going to a |
| 2436 | terminal) |
Junio C Hamano | cc0cb31 | 2009-01-22 03:38:50 | [diff] [blame] | 2437 | </p> |
| 2438 | </li> |
| 2439 | <li> |
| 2440 | <p> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2441 | <em>%m</em>: left, right or boundary mark |
| 2442 | </p> |
| 2443 | </li> |
| 2444 | <li> |
| 2445 | <p> |
| 2446 | <em>%n</em>: newline |
| 2447 | </p> |
| 2448 | </li> |
Junio C Hamano | b78d259 | 2008-04-09 09:39:08 | [diff] [blame] | 2449 | <li> |
| 2450 | <p> |
Junio C Hamano | a9701f0 | 2010-01-21 00:42:16 | [diff] [blame] | 2451 | <em>%%</em>: a raw <em>%</em> |
| 2452 | </p> |
| 2453 | </li> |
| 2454 | <li> |
| 2455 | <p> |
Junio C Hamano | b78d259 | 2008-04-09 09:39:08 | [diff] [blame] | 2456 | <em>%x00</em>: print a byte from a hex code |
| 2457 | </p> |
| 2458 | </li> |
Junio C Hamano | bf984de | 2009-11-23 06:11:19 | [diff] [blame] | 2459 | <li> |
| 2460 | <p> |
| 2461 | <em>%w([<w>[,<i1>[,<i2>]]])</em>: switch line wrapping, like the -w option of |
Junio C Hamano | a28a920 | 2012-06-21 07:08:23 | [diff] [blame] | 2462 | <a href="git-shortlog.html">git-shortlog(1)</a>. |
Junio C Hamano | bf984de | 2009-11-23 06:11:19 | [diff] [blame] | 2463 | </p> |
| 2464 | </li> |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 2465 | </ul></div> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2466 | </li> |
Junio C Hamano | c21ab05 | 2009-10-31 04:03:55 | [diff] [blame] | 2467 | </ul></div> |
| 2468 | <div class="admonitionblock"> |
| 2469 | <table><tr> |
| 2470 | <td class="icon"> |
| 2471 | <div class="title">Note</div> |
| 2472 | </td> |
| 2473 | <td class="content">Some placeholders may depend on other options given to the |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2474 | revision traversal engine. For example, the <code>%g*</code> reflog options will |
Junio C Hamano | c21ab05 | 2009-10-31 04:03:55 | [diff] [blame] | 2475 | insert an empty string unless we are traversing reflog entries (e.g., by |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2476 | <code>git log -g</code>). The <code>%d</code> placeholder will use the "short" decoration |
| 2477 | format if <code>--decorate</code> was not already provided on the command line.</td> |
Junio C Hamano | c21ab05 | 2009-10-31 04:03:55 | [diff] [blame] | 2478 | </tr></table> |
| 2479 | </div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2480 | <div class="paragraph"><p>If you add a <code>+</code> (plus sign) after <em>%</em> of a placeholder, a line-feed |
Junio C Hamano | 2bd8a74 | 2009-12-01 21:16:59 | [diff] [blame] | 2481 | is inserted immediately before the expansion if and only if the |
| 2482 | placeholder expands to a non-empty string.</p></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2483 | <div class="paragraph"><p>If you add a <code>-</code> (minus sign) after <em>%</em> of a placeholder, line-feeds that |
Junio C Hamano | 2bd8a74 | 2009-12-01 21:16:59 | [diff] [blame] | 2484 | immediately precede the expansion are deleted if and only if the |
| 2485 | placeholder expands to an empty string.</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 2486 | <div class="paragraph"><p>If you add a ` ` (space) after <em>%</em> of a placeholder, a space |
Junio C Hamano | 89a5734 | 2010-06-22 23:22:55 | [diff] [blame] | 2487 | is inserted immediately before the expansion if and only if the |
| 2488 | placeholder expands to a non-empty string.</p></div> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 2489 | <div class="ulist"><ul> |
Junio C Hamano | 6fb124c | 2008-06-13 10:04:01 | [diff] [blame] | 2490 | <li> |
| 2491 | <p> |
| 2492 | <em>tformat:</em> |
| 2493 | </p> |
Junio C Hamano | 68cf15a | 2010-11-06 01:01:59 | [diff] [blame] | 2494 | <div class="paragraph"><p>The <em>tformat:</em> format works exactly like <em>format:</em>, except that it |
Junio C Hamano | 6fb124c | 2008-06-13 10:04:01 | [diff] [blame] | 2495 | provides "terminator" semantics instead of "separator" semantics. In |
| 2496 | other words, each commit has the message terminator character (usually a |
| 2497 | newline) appended, rather than a separator placed between entries. |
| 2498 | This means that the final entry of a single-line format will be properly |
| 2499 | terminated with a new line, just as the "oneline" format does. |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 2500 | For example:</p></div> |
Junio C Hamano | 6fb124c | 2008-06-13 10:04:01 | [diff] [blame] | 2501 | <div class="listingblock"> |
| 2502 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2503 | <pre><code>$ git log -2 --pretty=format:%h 4da45bef \ |
Junio C Hamano | 6fb124c | 2008-06-13 10:04:01 | [diff] [blame] | 2504 | | perl -pe '$_ .= " -- NO NEWLINE\n" unless /\n/' |
| 2505 | 4da45be |
| 2506 | 7134973 -- NO NEWLINE |
| 2507 | |
| 2508 | $ git log -2 --pretty=tformat:%h 4da45bef \ |
| 2509 | | perl -pe '$_ .= " -- NO NEWLINE\n" unless /\n/' |
| 2510 | 4da45be |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2511 | 7134973</code></pre> |
Junio C Hamano | 6fb124c | 2008-06-13 10:04:01 | [diff] [blame] | 2512 | </div></div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2513 | <div class="paragraph"><p>In addition, any unrecognized string that has a <code>%</code> in it is interpreted |
| 2514 | as if it has <code>tformat:</code> in front of it. For example, these two are |
Junio C Hamano | 0a23522 | 2009-03-06 08:21:09 | [diff] [blame] | 2515 | equivalent:</p></div> |
| 2516 | <div class="listingblock"> |
| 2517 | <div class="content"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2518 | <pre><code>$ git log -2 --pretty=tformat:%h 4da45bef |
| 2519 | $ git log -2 --pretty=%h 4da45bef</code></pre> |
Junio C Hamano | 0a23522 | 2009-03-06 08:21:09 | [diff] [blame] | 2520 | </div></div> |
Junio C Hamano | 6fb124c | 2008-06-13 10:04:01 | [diff] [blame] | 2521 | </li> |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 2522 | </ul></div> |
Junio C Hamano | 0430e3a | 2007-05-15 03:13:17 | [diff] [blame] | 2523 | </div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2524 | </div> |
| 2525 | <div class="sect1"> |
Junio C Hamano | ba4b928 | 2008-07-06 05:20:31 | [diff] [blame] | 2526 | <h2 id="_git">GIT</h2> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 2527 | <div class="sectionbody"> |
Junio C Hamano | a28a920 | 2012-06-21 07:08:23 | [diff] [blame] | 2528 | <div class="paragraph"><p>Part of the <a href="git.html">git(1)</a> suite</p></div> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 2529 | </div> |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 2530 | </div> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 2531 | </div> |
Junio C Hamano | 7bd050f | 2011-09-22 06:32:22 | [diff] [blame] | 2532 | <div id="footnotes"><hr /></div> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 2533 | <div id="footer"> |
| 2534 | <div id="footer-text"> |
Junio C Hamano | 076ffcc | 2013-02-06 05:13:21 | [diff] [blame] | 2535 | Last updated 2013-02-05 21:07:26 PST |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 2536 | </div> |
| 2537 | </div> |
| 2538 | </body> |
| 2539 | </html> |