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> |
| 5 | <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> |
Junio C Hamano | 40f2f8d | 2006-02-07 08:04:39 | [diff] [blame] | 6 | <meta name="generator" content="AsciiDoc 7.0.2" /> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 7 | <style type="text/css"> |
| 8 | /* Debug borders */ |
| 9 | p, li, dt, dd, div, pre, h1, h2, h3, h4, h5, h6 { |
| 10 | /* |
| 11 | border: 1px solid red; |
| 12 | */ |
| 13 | } |
| 14 | |
| 15 | body { |
| 16 | margin: 1em 5% 1em 5%; |
| 17 | } |
| 18 | |
| 19 | a { color: blue; } |
| 20 | a:visited { color: fuchsia; } |
| 21 | |
| 22 | em { |
| 23 | font-style: italic; |
| 24 | } |
| 25 | |
| 26 | strong { |
| 27 | font-weight: bold; |
| 28 | } |
| 29 | |
| 30 | tt { |
| 31 | color: navy; |
| 32 | } |
| 33 | |
| 34 | h1, h2, h3, h4, h5, h6 { |
| 35 | color: #527bbd; |
| 36 | font-family: sans-serif; |
| 37 | margin-top: 1.2em; |
| 38 | margin-bottom: 0.5em; |
| 39 | line-height: 1.3; |
| 40 | } |
| 41 | |
| 42 | h1 { |
| 43 | border-bottom: 2px solid silver; |
| 44 | } |
| 45 | h2 { |
| 46 | border-bottom: 2px solid silver; |
| 47 | padding-top: 0.5em; |
| 48 | } |
| 49 | |
| 50 | div.sectionbody { |
| 51 | font-family: serif; |
| 52 | margin-left: 0; |
| 53 | } |
| 54 | |
| 55 | hr { |
| 56 | border: 1px solid silver; |
| 57 | } |
| 58 | |
| 59 | p { |
| 60 | margin-top: 0.5em; |
| 61 | margin-bottom: 0.5em; |
| 62 | } |
| 63 | |
| 64 | pre { |
| 65 | padding: 0; |
| 66 | margin: 0; |
| 67 | } |
| 68 | |
| 69 | span#author { |
| 70 | color: #527bbd; |
| 71 | font-family: sans-serif; |
| 72 | font-weight: bold; |
| 73 | font-size: 1.2em; |
| 74 | } |
| 75 | span#email { |
| 76 | } |
| 77 | span#revision { |
| 78 | font-family: sans-serif; |
| 79 | } |
| 80 | |
| 81 | div#footer { |
| 82 | font-family: sans-serif; |
| 83 | font-size: small; |
| 84 | border-top: 2px solid silver; |
| 85 | padding-top: 0.5em; |
| 86 | margin-top: 4.0em; |
| 87 | } |
| 88 | div#footer-text { |
| 89 | float: left; |
| 90 | padding-bottom: 0.5em; |
| 91 | } |
| 92 | div#footer-badges { |
| 93 | float: right; |
| 94 | padding-bottom: 0.5em; |
| 95 | } |
| 96 | |
| 97 | div#preamble, |
| 98 | div.tableblock, div.imageblock, div.exampleblock, div.verseblock, |
| 99 | div.quoteblock, div.literalblock, div.listingblock, div.sidebarblock, |
| 100 | div.admonitionblock { |
| 101 | margin-right: 10%; |
| 102 | margin-top: 1.5em; |
| 103 | margin-bottom: 1.5em; |
| 104 | } |
| 105 | div.admonitionblock { |
| 106 | margin-top: 2.5em; |
| 107 | margin-bottom: 2.5em; |
| 108 | } |
| 109 | |
| 110 | div.content { /* Block element content. */ |
| 111 | padding: 0; |
| 112 | } |
| 113 | |
| 114 | /* Block element titles. */ |
| 115 | div.title, caption.title { |
| 116 | font-family: sans-serif; |
| 117 | font-weight: bold; |
| 118 | text-align: left; |
| 119 | margin-top: 1.0em; |
| 120 | margin-bottom: 0.5em; |
| 121 | } |
| 122 | div.title + * { |
| 123 | margin-top: 0; |
| 124 | } |
| 125 | |
| 126 | td div.title:first-child { |
| 127 | margin-top: 0.0em; |
| 128 | } |
| 129 | div.content div.title:first-child { |
| 130 | margin-top: 0.0em; |
| 131 | } |
| 132 | div.content + div.title { |
| 133 | margin-top: 0.0em; |
| 134 | } |
| 135 | |
| 136 | div.sidebarblock > div.content { |
| 137 | background: #ffffee; |
| 138 | border: 1px solid silver; |
| 139 | padding: 0.5em; |
| 140 | } |
| 141 | |
| 142 | div.listingblock > div.content { |
| 143 | border: 1px solid silver; |
| 144 | background: #f4f4f4; |
| 145 | padding: 0.5em; |
| 146 | } |
| 147 | |
| 148 | div.quoteblock > div.content { |
| 149 | padding-left: 2.0em; |
| 150 | } |
| 151 | div.quoteblock .attribution { |
| 152 | text-align: right; |
| 153 | } |
| 154 | |
| 155 | div.admonitionblock .icon { |
| 156 | vertical-align: top; |
| 157 | font-size: 1.1em; |
| 158 | font-weight: bold; |
| 159 | text-decoration: underline; |
| 160 | color: #527bbd; |
| 161 | padding-right: 0.5em; |
| 162 | } |
| 163 | div.admonitionblock td.content { |
| 164 | padding-left: 0.5em; |
| 165 | border-left: 2px solid silver; |
| 166 | } |
| 167 | |
| 168 | div.exampleblock > div.content { |
| 169 | border-left: 2px solid silver; |
| 170 | padding: 0.5em; |
| 171 | } |
| 172 | |
| 173 | div.verseblock div.content { |
| 174 | white-space: pre; |
| 175 | } |
| 176 | |
| 177 | div.imageblock div.content { padding-left: 0; } |
| 178 | div.imageblock img { border: 1px solid silver; } |
| 179 | span.image img { border-style: none; } |
| 180 | |
| 181 | dl { |
| 182 | margin-top: 0.8em; |
| 183 | margin-bottom: 0.8em; |
| 184 | } |
| 185 | dt { |
| 186 | margin-top: 0.5em; |
| 187 | margin-bottom: 0; |
| 188 | font-style: italic; |
| 189 | } |
| 190 | dd > *:first-child { |
| 191 | margin-top: 0; |
| 192 | } |
| 193 | |
| 194 | ul, ol { |
| 195 | list-style-position: outside; |
| 196 | } |
| 197 | ol.olist2 { |
| 198 | list-style-type: lower-alpha; |
| 199 | } |
| 200 | |
| 201 | div.tableblock > table { |
| 202 | border-color: #527bbd; |
| 203 | border-width: 3px; |
| 204 | } |
| 205 | thead { |
| 206 | font-family: sans-serif; |
| 207 | font-weight: bold; |
| 208 | } |
| 209 | tfoot { |
| 210 | font-weight: bold; |
| 211 | } |
| 212 | |
| 213 | div.hlist { |
| 214 | margin-top: 0.8em; |
| 215 | margin-bottom: 0.8em; |
| 216 | } |
| 217 | td.hlist1 { |
| 218 | vertical-align: top; |
| 219 | font-style: italic; |
| 220 | padding-right: 0.8em; |
| 221 | } |
| 222 | td.hlist2 { |
| 223 | vertical-align: top; |
| 224 | } |
| 225 | |
| 226 | @media print { |
| 227 | div#footer-badges { display: none; } |
| 228 | } |
| 229 | include::./stylesheets/xhtml11-manpage.css[] |
| 230 | /* Workarounds for IE6's broken and incomplete CSS2. */ |
| 231 | |
| 232 | div.sidebar-content { |
| 233 | background: #ffffee; |
| 234 | border: 1px solid silver; |
| 235 | padding: 0.5em; |
| 236 | } |
| 237 | div.sidebar-title, div.image-title { |
| 238 | font-family: sans-serif; |
| 239 | font-weight: bold; |
| 240 | margin-top: 0.0em; |
| 241 | margin-bottom: 0.5em; |
| 242 | } |
| 243 | |
| 244 | div.listingblock div.content { |
| 245 | border: 1px solid silver; |
| 246 | background: #f4f4f4; |
| 247 | padding: 0.5em; |
| 248 | } |
| 249 | |
| 250 | div.quoteblock-content { |
| 251 | padding-left: 2.0em; |
| 252 | } |
| 253 | |
| 254 | div.exampleblock-content { |
| 255 | border-left: 2px solid silver; |
| 256 | padding-left: 0.5em; |
| 257 | } |
| 258 | </style> |
| 259 | <title>git-commit(1)</title> |
| 260 | </head> |
| 261 | <body> |
| 262 | <div id="header"> |
| 263 | <h1> |
| 264 | git-commit(1) Manual Page |
| 265 | </h1> |
| 266 | <h2>NAME</h2> |
| 267 | <div class="sectionbody"> |
| 268 | <p>git-commit - |
| 269 | Record your changes |
| 270 | </p> |
| 271 | </div> |
| 272 | </div> |
| 273 | <h2>SYNOPSIS</h2> |
| 274 | <div class="sectionbody"> |
Junio C Hamano | 235a91e | 2006-01-07 01:13:58 | [diff] [blame] | 275 | <div class="verseblock"> |
Junio C Hamano | 6697ac5 | 2006-02-14 08:00:23 | [diff] [blame] | 276 | <div class="content"><em>git-commit</em> [-a] [-s] [-v] [(-c | -C) <commit> | -F <file> | -m <msg>] |
Junio C Hamano | bfe9e75 | 2006-04-05 21:43:28 | [diff] [blame] | 277 | [--no-verify] [--amend] [-e] [--author <author>] |
| 278 | [--] [[-i | -o ]<file>…]</div></div> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 279 | </div> |
| 280 | <h2>DESCRIPTION</h2> |
| 281 | <div class="sectionbody"> |
Junio C Hamano | e7935c4 | 2006-12-13 21:32:17 | [diff] [blame] | 282 | <p>Use <em>git commit</em> when you want to record your changes into the repository |
| 283 | along with a log message describing what the commit is about. All changes |
| 284 | to be committed must be explicitly identified using one of the following |
| 285 | methods:</p> |
| 286 | <ol> |
| 287 | <li> |
| 288 | <p> |
| 289 | by using <a href="git-add.html">git-add(1)</a> to incrementally "add" changes to the |
| 290 | next commit before using the <em>commit</em> command (Note: even modified |
| 291 | files must be "added"); |
| 292 | </p> |
| 293 | </li> |
| 294 | <li> |
| 295 | <p> |
| 296 | by using <a href="git-rm.html">git-rm(1)</a> to identify content removal for the next |
| 297 | commit, again before using the <em>commit</em> command; |
| 298 | </p> |
| 299 | </li> |
| 300 | <li> |
| 301 | <p> |
| 302 | by directly listing files containing changes to be committed as arguments |
| 303 | to the <em>commit</em> command, in which cases only those files alone will be |
| 304 | considered for the commit; |
| 305 | </p> |
| 306 | </li> |
| 307 | <li> |
| 308 | <p> |
| 309 | by using the -a switch with the <em>commit</em> command to automatically "add" |
| 310 | changes from all known files i.e. files that have already been committed |
| 311 | before, and perform the actual commit. |
| 312 | </p> |
| 313 | </li> |
| 314 | </ol> |
| 315 | <p>The <a href="git-status.html">git-status(1)</a> command can be used to obtain a |
| 316 | summary of what is included by any of the above for the next |
| 317 | commit by giving the same set of parameters you would give to |
| 318 | this command.</p> |
| 319 | <p>If you make a commit and then found a mistake immediately after |
| 320 | that, you can recover from it with <a href="git-reset.html">git-reset(1)</a>.</p> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 321 | </div> |
| 322 | <h2>OPTIONS</h2> |
| 323 | <div class="sectionbody"> |
| 324 | <dl> |
| 325 | <dt> |
| 326 | -a|--all |
| 327 | </dt> |
| 328 | <dd> |
| 329 | <p> |
Junio C Hamano | e7935c4 | 2006-12-13 21:32:17 | [diff] [blame] | 330 | Tell the command to automatically stage files that have |
| 331 | been modified and deleted, but new files you have not |
| 332 | told git about are not affected. |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 333 | </p> |
| 334 | </dd> |
| 335 | <dt> |
| 336 | -c or -C <commit> |
| 337 | </dt> |
| 338 | <dd> |
| 339 | <p> |
| 340 | Take existing commit object, and reuse the log message |
| 341 | and the authorship information (including the timestamp) |
| 342 | when creating the commit. With <em>-C</em>, the editor is not |
| 343 | invoked; with <em>-c</em> the user can further edit the commit |
| 344 | message. |
| 345 | </p> |
| 346 | </dd> |
| 347 | <dt> |
| 348 | -F <file> |
| 349 | </dt> |
| 350 | <dd> |
| 351 | <p> |
| 352 | Take the commit message from the given file. Use <em>-</em> to |
| 353 | read the message from the standard input. |
| 354 | </p> |
| 355 | </dd> |
| 356 | <dt> |
Junio C Hamano | 40f2f8d | 2006-02-07 08:04:39 | [diff] [blame] | 357 | --author <author> |
| 358 | </dt> |
| 359 | <dd> |
| 360 | <p> |
| 361 | Override the author name used in the commit. Use |
| 362 | <tt>A U Thor <author@example.com></tt> format. |
| 363 | </p> |
| 364 | </dd> |
| 365 | <dt> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 366 | -m <msg> |
| 367 | </dt> |
| 368 | <dd> |
| 369 | <p> |
| 370 | Use the given <msg> as the commit message. |
| 371 | </p> |
| 372 | </dd> |
| 373 | <dt> |
| 374 | -s|--signoff |
| 375 | </dt> |
| 376 | <dd> |
| 377 | <p> |
| 378 | Add Signed-off-by line at the end of the commit message. |
| 379 | </p> |
| 380 | </dd> |
| 381 | <dt> |
Junio C Hamano | e7935c4 | 2006-12-13 21:32:17 | [diff] [blame] | 382 | --no-verify |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 383 | </dt> |
| 384 | <dd> |
| 385 | <p> |
Junio C Hamano | e7935c4 | 2006-12-13 21:32:17 | [diff] [blame] | 386 | By default, the command looks for suspicious lines the |
| 387 | commit introduces, and aborts committing if there is one. |
| 388 | The definition of <em>suspicious lines</em> is currently the |
| 389 | lines that has trailing whitespaces, and the lines whose |
| 390 | indentation has a SP character immediately followed by a |
| 391 | TAB character. This option turns off the check. |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 392 | </p> |
| 393 | </dd> |
| 394 | <dt> |
| 395 | -e|--edit |
| 396 | </dt> |
| 397 | <dd> |
| 398 | <p> |
| 399 | The message taken from file with <tt>-F</tt>, command line with |
| 400 | <tt>-m</tt>, and from file with <tt>-C</tt> are usually used as the |
| 401 | commit log message unmodified. This option lets you |
| 402 | further edit the message taken from these sources. |
| 403 | </p> |
| 404 | </dd> |
| 405 | <dt> |
Junio C Hamano | bfe9e75 | 2006-04-05 21:43:28 | [diff] [blame] | 406 | --amend |
| 407 | </dt> |
| 408 | <dd> |
| 409 | <p> |
| 410 | Used to amend the tip of the current branch. Prepare the tree |
| 411 | object you would want to replace the latest commit as usual |
| 412 | (this includes the usual -i/-o and explicit paths), and the |
| 413 | commit log editor is seeded with the commit message from the |
| 414 | tip of the current branch. The commit you create replaces the |
| 415 | current tip — if it was a merge, it will have the parents of |
| 416 | the current tip as parents — so the current top commit is |
| 417 | discarded. |
| 418 | </p> |
| 419 | <p>It is a rough equivalent for:</p> |
| 420 | <div class="listingblock"> |
| 421 | <div class="content"> |
| 422 | <pre><tt> $ git reset --soft HEAD^ |
| 423 | $ ... do something else to come up with the right tree ... |
Junio C Hamano | 47ea30e | 2006-04-05 23:08:03 | [diff] [blame] | 424 | $ git commit -c ORIG_HEAD |
| 425 | </tt></pre> |
Junio C Hamano | bfe9e75 | 2006-04-05 21:43:28 | [diff] [blame] | 426 | </div></div> |
| 427 | <p>but can be used to amend a merge commit.</p> |
| 428 | </dd> |
| 429 | <dt> |
Junio C Hamano | 40f2f8d | 2006-02-07 08:04:39 | [diff] [blame] | 430 | -i|--include |
| 431 | </dt> |
| 432 | <dd> |
| 433 | <p> |
Junio C Hamano | e7935c4 | 2006-12-13 21:32:17 | [diff] [blame] | 434 | Before making a commit out of staged contents so far, |
| 435 | stage the contents of paths given on the command line |
| 436 | as well. This is usually not what you want unless you |
| 437 | are concluding a conflicted merge. |
Junio C Hamano | 6697ac5 | 2006-02-14 08:00:23 | [diff] [blame] | 438 | </p> |
| 439 | </dd> |
| 440 | <dt> |
Junio C Hamano | 7d23f5e | 2006-12-16 07:44:04 | [diff] [blame] | 441 | -q|--quiet |
| 442 | </dt> |
| 443 | <dd> |
| 444 | <p> |
| 445 | Supress commit summary message. |
| 446 | </p> |
| 447 | </dd> |
| 448 | <dt> |
Junio C Hamano | 1bb569e | 2006-05-05 23:14:25 | [diff] [blame] | 449 | -- |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 450 | </dt> |
| 451 | <dd> |
| 452 | <p> |
| 453 | Do not interpret any more arguments as options. |
| 454 | </p> |
| 455 | </dd> |
| 456 | <dt> |
| 457 | <file>… |
| 458 | </dt> |
| 459 | <dd> |
| 460 | <p> |
Junio C Hamano | e7935c4 | 2006-12-13 21:32:17 | [diff] [blame] | 461 | When files are given on the command line, the command |
| 462 | commits the contents of the named files, without |
| 463 | recording the changes already staged. The contents of |
| 464 | these files are also staged for the next commit on top |
| 465 | of what have been staged before. |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 466 | </p> |
| 467 | </dd> |
| 468 | </dl> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 469 | </div> |
Junio C Hamano | e7935c4 | 2006-12-13 21:32:17 | [diff] [blame] | 470 | <h2>EXAMPLES</h2> |
Junio C Hamano | 40f2f8d | 2006-02-07 08:04:39 | [diff] [blame] | 471 | <div class="sectionbody"> |
Junio C Hamano | e7935c4 | 2006-12-13 21:32:17 | [diff] [blame] | 472 | <p>When recording your own work, the contents of modified files in |
| 473 | your working tree are temporarily stored to a staging area |
| 474 | called the "index" with <a href="git-add.html">git-add(1)</a>. Removal |
| 475 | of a file is staged with <a href="git-rm.html">git-rm(1)</a>. After building the |
| 476 | state to be committed incrementally with these commands, <tt>git |
| 477 | commit</tt> (without any pathname parameter) is used to record what |
| 478 | has been staged so far. This is the most basic form of the |
| 479 | command. An example:</p> |
| 480 | <div class="listingblock"> |
Junio C Hamano | 40f2f8d | 2006-02-07 08:04:39 | [diff] [blame] | 481 | <div class="content"> |
Junio C Hamano | e7935c4 | 2006-12-13 21:32:17 | [diff] [blame] | 482 | <pre><tt>$ edit hello.c |
| 483 | $ git rm goodbye.c |
| 484 | $ git add hello.c |
| 485 | $ git commit</tt></pre> |
Junio C Hamano | 40f2f8d | 2006-02-07 08:04:39 | [diff] [blame] | 486 | </div></div> |
Junio C Hamano | e7935c4 | 2006-12-13 21:32:17 | [diff] [blame] | 487 | <p>Instead of staging files after each individual change, you can |
| 488 | tell <tt>git commit</tt> to notice the changes to the files whose |
| 489 | contents are tracked in |
| 490 | your working tree and do corresponding <tt>git add</tt> and <tt>git rm</tt> |
| 491 | for you. That is, this example does the same as the earlier |
| 492 | example if there is no other change in your working tree:</p> |
| 493 | <div class="listingblock"> |
| 494 | <div class="content"> |
| 495 | <pre><tt>$ edit hello.c |
| 496 | $ rm goodbye.c |
| 497 | $ git commit -a</tt></pre> |
| 498 | </div></div> |
| 499 | <p>The command <tt>git commit -a</tt> first looks at your working tree, |
| 500 | notices that you have modified hello.c and removed goodbye.c, |
| 501 | and performs necessary <tt>git add</tt> and <tt>git rm</tt> for you.</p> |
| 502 | <p>After staging changes to many files, you can alter the order the |
| 503 | changes are recorded in, by giving pathnames to <tt>git commit</tt>. |
| 504 | When pathnames are given, the command makes a commit that |
| 505 | only records the changes made to the named paths:</p> |
| 506 | <div class="listingblock"> |
| 507 | <div class="content"> |
| 508 | <pre><tt>$ edit hello.c hello.h |
| 509 | $ git add hello.c hello.h |
| 510 | $ edit Makefile |
| 511 | $ git commit Makefile</tt></pre> |
| 512 | </div></div> |
| 513 | <p>This makes a commit that records the modification to <tt>Makefile</tt>. |
| 514 | The changes staged for <tt>hello.c</tt> and <tt>hello.h</tt> are not included |
| 515 | in the resulting commit. However, their changes are not lost — |
| 516 | they are still staged and merely held back. After the above |
| 517 | sequence, if you do:</p> |
| 518 | <div class="listingblock"> |
| 519 | <div class="content"> |
| 520 | <pre><tt>$ git commit</tt></pre> |
| 521 | </div></div> |
| 522 | <p>this second commit would record the changes to <tt>hello.c</tt> and |
| 523 | <tt>hello.h</tt> as expected.</p> |
| 524 | <p>After a merge (initiated by either <a href="git-merge.html">git-merge(1)</a> or |
| 525 | <a href="git-pull.html">git-pull(1)</a>) stops because of conflicts, cleanly merged |
| 526 | paths are already staged to be committed for you, and paths that |
| 527 | conflicted are left in unmerged state. You would have to first |
| 528 | check which paths are conflicting with <a href="git-status.html">git-status(1)</a> |
| 529 | and after fixing them manually in your working tree, you would |
| 530 | stage the result as usual with <a href="git-add.html">git-add(1)</a>:</p> |
| 531 | <div class="listingblock"> |
| 532 | <div class="content"> |
| 533 | <pre><tt>$ git status | grep unmerged |
| 534 | unmerged: hello.c |
| 535 | $ edit hello.c |
| 536 | $ git add hello.c</tt></pre> |
| 537 | </div></div> |
| 538 | <p>After resolving conflicts and staging the result, <tt>git ls-files -u</tt> |
| 539 | would stop mentioning the conflicted path. When you are done, |
| 540 | run <tt>git commit</tt> to finally record the merge:</p> |
| 541 | <div class="listingblock"> |
| 542 | <div class="content"> |
| 543 | <pre><tt>$ git commit</tt></pre> |
| 544 | </div></div> |
| 545 | <p>As with the case to record your own changes, you can use <tt>-a</tt> |
| 546 | option to save typing. One difference is that during a merge |
| 547 | resolution, you cannot use <tt>git commit</tt> with pathnames to |
| 548 | alter the order the changes are committed, because the merge |
| 549 | should be recorded as a single commit. In fact, the command |
| 550 | refuses to run when given pathnames (but see <tt>-i</tt> option).</p> |
| 551 | </div> |
| 552 | <h2>ENVIRONMENT VARIABLES</h2> |
| 553 | <div class="sectionbody"> |
| 554 | <p>The command specified by either the VISUAL or EDITOR environment |
| 555 | variables is used to edit the commit log message.</p> |
| 556 | </div> |
| 557 | <h2>HOOKS</h2> |
| 558 | <div class="sectionbody"> |
| 559 | <p>This command can run <tt>commit-msg</tt>, <tt>pre-commit</tt>, and |
| 560 | <tt>post-commit</tt> hooks. See <a href="hooks.html">hooks</a> for more |
| 561 | information.</p> |
| 562 | </div> |
| 563 | <h2>SEE ALSO</h2> |
| 564 | <div class="sectionbody"> |
| 565 | <p><a href="git-add.html">git-add(1)</a>, |
| 566 | <a href="git-rm.html">git-rm(1)</a>, |
| 567 | <a href="git-mv.html">git-mv(1)</a>, |
| 568 | <a href="git-merge.html">git-merge(1)</a>, |
| 569 | <a href="git-commit-tree.html">git-commit-tree(1)</a></p> |
Junio C Hamano | 40f2f8d | 2006-02-07 08:04:39 | [diff] [blame] | 570 | </div> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 571 | <h2>Author</h2> |
| 572 | <div class="sectionbody"> |
| 573 | <p>Written by Linus Torvalds <torvalds@osdl.org> and |
| 574 | Junio C Hamano <junkio@cox.net></p> |
| 575 | </div> |
| 576 | <h2>GIT</h2> |
| 577 | <div class="sectionbody"> |
| 578 | <p>Part of the <a href="git.html">git(7)</a> suite</p> |
| 579 | </div> |
| 580 | <div id="footer"> |
| 581 | <div id="footer-text"> |
Junio C Hamano | 7d23f5e | 2006-12-16 07:44:04 | [diff] [blame] | 582 | Last updated 16-Dec-2006 07:43:46 UTC |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 583 | </div> |
| 584 | </div> |
| 585 | </body> |
| 586 | </html> |