Junio C Hamano | 944ce25 | 2018-05-30 22:25:26 | [diff] [blame] | 1 | <?xml version="1.0" encoding="UTF-8"?> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" |
| 3 | "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> |
| 4 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> |
| 5 | <head> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 6 | <meta http-equiv="Content-Type" content="application/xhtml+xml; charset=UTF-8" /> |
Junio C Hamano | eaa95f7 | 2020-04-14 17:39:35 | [diff] [blame] | 7 | <meta name="generator" content="AsciiDoc 9.0.0rc1" /> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 8 | <title>How to maintain Git</title> |
| 9 | <style type="text/css"> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 10 | /* Shared CSS for AsciiDoc xhtml11 and html5 backends */ |
| 11 | |
| 12 | /* Default font. */ |
| 13 | body { |
| 14 | font-family: Georgia,serif; |
| 15 | } |
| 16 | |
| 17 | /* Title font. */ |
| 18 | h1, h2, h3, h4, h5, h6, |
| 19 | div.title, caption.title, |
| 20 | thead, p.table.header, |
| 21 | #toctitle, |
| 22 | #author, #revnumber, #revdate, #revremark, |
| 23 | #footer { |
| 24 | font-family: Arial,Helvetica,sans-serif; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 25 | } |
| 26 | |
| 27 | body { |
| 28 | margin: 1em 5% 1em 5%; |
| 29 | } |
| 30 | |
| 31 | a { |
| 32 | color: blue; |
| 33 | text-decoration: underline; |
| 34 | } |
| 35 | a:visited { |
| 36 | color: fuchsia; |
| 37 | } |
| 38 | |
| 39 | em { |
| 40 | font-style: italic; |
| 41 | color: navy; |
| 42 | } |
| 43 | |
| 44 | strong { |
| 45 | font-weight: bold; |
| 46 | color: #083194; |
| 47 | } |
| 48 | |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 49 | h1, h2, h3, h4, h5, h6 { |
| 50 | color: #527bbd; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 51 | margin-top: 1.2em; |
| 52 | margin-bottom: 0.5em; |
| 53 | line-height: 1.3; |
| 54 | } |
| 55 | |
| 56 | h1, h2, h3 { |
| 57 | border-bottom: 2px solid silver; |
| 58 | } |
| 59 | h2 { |
| 60 | padding-top: 0.5em; |
| 61 | } |
| 62 | h3 { |
| 63 | float: left; |
| 64 | } |
| 65 | h3 + * { |
| 66 | clear: left; |
| 67 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 68 | h5 { |
| 69 | font-size: 1.0em; |
| 70 | } |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 71 | |
| 72 | div.sectionbody { |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 73 | margin-left: 0; |
| 74 | } |
| 75 | |
| 76 | hr { |
| 77 | border: 1px solid silver; |
| 78 | } |
| 79 | |
| 80 | p { |
| 81 | margin-top: 0.5em; |
| 82 | margin-bottom: 0.5em; |
| 83 | } |
| 84 | |
| 85 | ul, ol, li > p { |
| 86 | margin-top: 0; |
| 87 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 88 | ul > li { color: #aaa; } |
| 89 | ul > li > * { color: black; } |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 90 | |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 91 | .monospaced, code, pre { |
| 92 | font-family: "Courier New", Courier, monospace; |
| 93 | font-size: inherit; |
| 94 | color: navy; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 95 | padding: 0; |
| 96 | margin: 0; |
| 97 | } |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 98 | pre { |
| 99 | white-space: pre-wrap; |
| 100 | } |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 101 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 102 | #author { |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 103 | color: #527bbd; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 104 | font-weight: bold; |
| 105 | font-size: 1.1em; |
| 106 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 107 | #email { |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 108 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 109 | #revnumber, #revdate, #revremark { |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 110 | } |
| 111 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 112 | #footer { |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 113 | font-size: small; |
| 114 | border-top: 2px solid silver; |
| 115 | padding-top: 0.5em; |
| 116 | margin-top: 4.0em; |
| 117 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 118 | #footer-text { |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 119 | float: left; |
| 120 | padding-bottom: 0.5em; |
| 121 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 122 | #footer-badges { |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 123 | float: right; |
| 124 | padding-bottom: 0.5em; |
| 125 | } |
| 126 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 127 | #preamble { |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 128 | margin-top: 1.5em; |
| 129 | margin-bottom: 1.5em; |
| 130 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 131 | div.imageblock, div.exampleblock, div.verseblock, |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 132 | div.quoteblock, div.literalblock, div.listingblock, div.sidebarblock, |
| 133 | div.admonitionblock { |
| 134 | margin-top: 1.0em; |
| 135 | margin-bottom: 1.5em; |
| 136 | } |
| 137 | div.admonitionblock { |
| 138 | margin-top: 2.0em; |
| 139 | margin-bottom: 2.0em; |
| 140 | margin-right: 10%; |
| 141 | color: #606060; |
| 142 | } |
| 143 | |
| 144 | div.content { /* Block element content. */ |
| 145 | padding: 0; |
| 146 | } |
| 147 | |
| 148 | /* Block element titles. */ |
| 149 | div.title, caption.title { |
| 150 | color: #527bbd; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 151 | font-weight: bold; |
| 152 | text-align: left; |
| 153 | margin-top: 1.0em; |
| 154 | margin-bottom: 0.5em; |
| 155 | } |
| 156 | div.title + * { |
| 157 | margin-top: 0; |
| 158 | } |
| 159 | |
| 160 | td div.title:first-child { |
| 161 | margin-top: 0.0em; |
| 162 | } |
| 163 | div.content div.title:first-child { |
| 164 | margin-top: 0.0em; |
| 165 | } |
| 166 | div.content + div.title { |
| 167 | margin-top: 0.0em; |
| 168 | } |
| 169 | |
| 170 | div.sidebarblock > div.content { |
| 171 | background: #ffffee; |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 172 | border: 1px solid #dddddd; |
| 173 | border-left: 4px solid #f0f0f0; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 174 | padding: 0.5em; |
| 175 | } |
| 176 | |
| 177 | div.listingblock > div.content { |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 178 | border: 1px solid #dddddd; |
| 179 | border-left: 5px solid #f0f0f0; |
| 180 | background: #f8f8f8; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 181 | padding: 0.5em; |
| 182 | } |
| 183 | |
| 184 | div.quoteblock, div.verseblock { |
| 185 | padding-left: 1.0em; |
| 186 | margin-left: 1.0em; |
| 187 | margin-right: 10%; |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 188 | border-left: 5px solid #f0f0f0; |
| 189 | color: #888; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 190 | } |
| 191 | |
| 192 | div.quoteblock > div.attribution { |
| 193 | padding-top: 0.5em; |
| 194 | text-align: right; |
| 195 | } |
| 196 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 197 | div.verseblock > pre.content { |
| 198 | font-family: inherit; |
| 199 | font-size: inherit; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 200 | } |
| 201 | div.verseblock > div.attribution { |
| 202 | padding-top: 0.75em; |
| 203 | text-align: left; |
| 204 | } |
| 205 | /* DEPRECATED: Pre version 8.2.7 verse style literal block. */ |
| 206 | div.verseblock + div.attribution { |
| 207 | text-align: left; |
| 208 | } |
| 209 | |
| 210 | div.admonitionblock .icon { |
| 211 | vertical-align: top; |
| 212 | font-size: 1.1em; |
| 213 | font-weight: bold; |
| 214 | text-decoration: underline; |
| 215 | color: #527bbd; |
| 216 | padding-right: 0.5em; |
| 217 | } |
| 218 | div.admonitionblock td.content { |
| 219 | padding-left: 0.5em; |
| 220 | border-left: 3px solid #dddddd; |
| 221 | } |
| 222 | |
| 223 | div.exampleblock > div.content { |
| 224 | border-left: 3px solid #dddddd; |
| 225 | padding-left: 0.5em; |
| 226 | } |
| 227 | |
| 228 | div.imageblock div.content { padding-left: 0; } |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 229 | span.image img { border-style: none; vertical-align: text-bottom; } |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 230 | a.image:visited { color: white; } |
| 231 | |
| 232 | dl { |
| 233 | margin-top: 0.8em; |
| 234 | margin-bottom: 0.8em; |
| 235 | } |
| 236 | dt { |
| 237 | margin-top: 0.5em; |
| 238 | margin-bottom: 0; |
| 239 | font-style: normal; |
| 240 | color: navy; |
| 241 | } |
| 242 | dd > *:first-child { |
| 243 | margin-top: 0.1em; |
| 244 | } |
| 245 | |
| 246 | ul, ol { |
| 247 | list-style-position: outside; |
| 248 | } |
| 249 | ol.arabic { |
| 250 | list-style-type: decimal; |
| 251 | } |
| 252 | ol.loweralpha { |
| 253 | list-style-type: lower-alpha; |
| 254 | } |
| 255 | ol.upperalpha { |
| 256 | list-style-type: upper-alpha; |
| 257 | } |
| 258 | ol.lowerroman { |
| 259 | list-style-type: lower-roman; |
| 260 | } |
| 261 | ol.upperroman { |
| 262 | list-style-type: upper-roman; |
| 263 | } |
| 264 | |
| 265 | div.compact ul, div.compact ol, |
| 266 | div.compact p, div.compact p, |
| 267 | div.compact div, div.compact div { |
| 268 | margin-top: 0.1em; |
| 269 | margin-bottom: 0.1em; |
| 270 | } |
| 271 | |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 272 | tfoot { |
| 273 | font-weight: bold; |
| 274 | } |
| 275 | td > div.verse { |
| 276 | white-space: pre; |
| 277 | } |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 278 | |
| 279 | div.hdlist { |
| 280 | margin-top: 0.8em; |
| 281 | margin-bottom: 0.8em; |
| 282 | } |
| 283 | div.hdlist tr { |
| 284 | padding-bottom: 15px; |
| 285 | } |
| 286 | dt.hdlist1.strong, td.hdlist1.strong { |
| 287 | font-weight: bold; |
| 288 | } |
| 289 | td.hdlist1 { |
| 290 | vertical-align: top; |
| 291 | font-style: normal; |
| 292 | padding-right: 0.8em; |
| 293 | color: navy; |
| 294 | } |
| 295 | td.hdlist2 { |
| 296 | vertical-align: top; |
| 297 | } |
| 298 | div.hdlist.compact tr { |
| 299 | margin: 0; |
| 300 | padding-bottom: 0; |
| 301 | } |
| 302 | |
| 303 | .comment { |
| 304 | background: yellow; |
| 305 | } |
| 306 | |
| 307 | .footnote, .footnoteref { |
| 308 | font-size: 0.8em; |
| 309 | } |
| 310 | |
| 311 | span.footnote, span.footnoteref { |
| 312 | vertical-align: super; |
| 313 | } |
| 314 | |
| 315 | #footnotes { |
| 316 | margin: 20px 0 20px 0; |
| 317 | padding: 7px 0 0 0; |
| 318 | } |
| 319 | |
| 320 | #footnotes div.footnote { |
| 321 | margin: 0 0 5px 0; |
| 322 | } |
| 323 | |
| 324 | #footnotes hr { |
| 325 | border: none; |
| 326 | border-top: 1px solid silver; |
| 327 | height: 1px; |
| 328 | text-align: left; |
| 329 | margin-left: 0; |
| 330 | width: 20%; |
| 331 | min-width: 100px; |
| 332 | } |
| 333 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 334 | div.colist td { |
| 335 | padding-right: 0.5em; |
| 336 | padding-bottom: 0.3em; |
| 337 | vertical-align: top; |
| 338 | } |
| 339 | div.colist td img { |
| 340 | margin-top: 0.3em; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 341 | } |
| 342 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 343 | @media print { |
| 344 | #footer-badges { display: none; } |
| 345 | } |
| 346 | |
| 347 | #toc { |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 348 | margin-bottom: 2.5em; |
| 349 | } |
| 350 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 351 | #toctitle { |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 352 | color: #527bbd; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 353 | font-size: 1.1em; |
| 354 | font-weight: bold; |
| 355 | margin-top: 1.0em; |
| 356 | margin-bottom: 0.1em; |
| 357 | } |
| 358 | |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 359 | div.toclevel0, div.toclevel1, div.toclevel2, div.toclevel3, div.toclevel4 { |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 360 | margin-top: 0; |
| 361 | margin-bottom: 0; |
| 362 | } |
| 363 | div.toclevel2 { |
| 364 | margin-left: 2em; |
| 365 | font-size: 0.9em; |
| 366 | } |
| 367 | div.toclevel3 { |
| 368 | margin-left: 4em; |
| 369 | font-size: 0.9em; |
| 370 | } |
| 371 | div.toclevel4 { |
| 372 | margin-left: 6em; |
| 373 | font-size: 0.9em; |
| 374 | } |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 375 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 376 | span.aqua { color: aqua; } |
| 377 | span.black { color: black; } |
| 378 | span.blue { color: blue; } |
| 379 | span.fuchsia { color: fuchsia; } |
| 380 | span.gray { color: gray; } |
| 381 | span.green { color: green; } |
| 382 | span.lime { color: lime; } |
| 383 | span.maroon { color: maroon; } |
| 384 | span.navy { color: navy; } |
| 385 | span.olive { color: olive; } |
| 386 | span.purple { color: purple; } |
| 387 | span.red { color: red; } |
| 388 | span.silver { color: silver; } |
| 389 | span.teal { color: teal; } |
| 390 | span.white { color: white; } |
| 391 | span.yellow { color: yellow; } |
| 392 | |
| 393 | span.aqua-background { background: aqua; } |
| 394 | span.black-background { background: black; } |
| 395 | span.blue-background { background: blue; } |
| 396 | span.fuchsia-background { background: fuchsia; } |
| 397 | span.gray-background { background: gray; } |
| 398 | span.green-background { background: green; } |
| 399 | span.lime-background { background: lime; } |
| 400 | span.maroon-background { background: maroon; } |
| 401 | span.navy-background { background: navy; } |
| 402 | span.olive-background { background: olive; } |
| 403 | span.purple-background { background: purple; } |
| 404 | span.red-background { background: red; } |
| 405 | span.silver-background { background: silver; } |
| 406 | span.teal-background { background: teal; } |
| 407 | span.white-background { background: white; } |
| 408 | span.yellow-background { background: yellow; } |
| 409 | |
| 410 | span.big { font-size: 2em; } |
| 411 | span.small { font-size: 0.6em; } |
| 412 | |
| 413 | span.underline { text-decoration: underline; } |
| 414 | span.overline { text-decoration: overline; } |
| 415 | span.line-through { text-decoration: line-through; } |
| 416 | |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 417 | div.unbreakable { page-break-inside: avoid; } |
| 418 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 419 | |
| 420 | /* |
| 421 | * xhtml11 specific |
| 422 | * |
| 423 | * */ |
| 424 | |
| 425 | div.tableblock { |
| 426 | margin-top: 1.0em; |
| 427 | margin-bottom: 1.5em; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 428 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 429 | div.tableblock > table { |
| 430 | border: 3px solid #527bbd; |
| 431 | } |
| 432 | thead, p.table.header { |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 433 | font-weight: bold; |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 434 | color: #527bbd; |
| 435 | } |
| 436 | p.table { |
| 437 | margin-top: 0; |
| 438 | } |
Junio C Hamano | 725b0da | 2020-01-22 22:02:40 | [diff] [blame] | 439 | /* Because the table frame attribute is overridden by CSS in most browsers. */ |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 440 | div.tableblock > table[frame="void"] { |
| 441 | border-style: none; |
| 442 | } |
| 443 | div.tableblock > table[frame="hsides"] { |
| 444 | border-left-style: none; |
| 445 | border-right-style: none; |
| 446 | } |
| 447 | div.tableblock > table[frame="vsides"] { |
| 448 | border-top-style: none; |
| 449 | border-bottom-style: none; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 450 | } |
| 451 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 452 | |
| 453 | /* |
| 454 | * html5 specific |
| 455 | * |
| 456 | * */ |
| 457 | |
| 458 | table.tableblock { |
| 459 | margin-top: 1.0em; |
| 460 | margin-bottom: 1.5em; |
| 461 | } |
| 462 | thead, p.tableblock.header { |
| 463 | font-weight: bold; |
| 464 | color: #527bbd; |
| 465 | } |
| 466 | p.tableblock { |
| 467 | margin-top: 0; |
| 468 | } |
| 469 | table.tableblock { |
| 470 | border-width: 3px; |
| 471 | border-spacing: 0px; |
| 472 | border-style: solid; |
| 473 | border-color: #527bbd; |
| 474 | border-collapse: collapse; |
| 475 | } |
| 476 | th.tableblock, td.tableblock { |
| 477 | border-width: 1px; |
| 478 | padding: 4px; |
| 479 | border-style: solid; |
| 480 | border-color: #527bbd; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 481 | } |
| 482 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 483 | table.tableblock.frame-topbot { |
| 484 | border-left-style: hidden; |
| 485 | border-right-style: hidden; |
| 486 | } |
| 487 | table.tableblock.frame-sides { |
| 488 | border-top-style: hidden; |
| 489 | border-bottom-style: hidden; |
| 490 | } |
| 491 | table.tableblock.frame-none { |
| 492 | border-style: hidden; |
| 493 | } |
| 494 | |
| 495 | th.tableblock.halign-left, td.tableblock.halign-left { |
| 496 | text-align: left; |
| 497 | } |
| 498 | th.tableblock.halign-center, td.tableblock.halign-center { |
| 499 | text-align: center; |
| 500 | } |
| 501 | th.tableblock.halign-right, td.tableblock.halign-right { |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 502 | text-align: right; |
| 503 | } |
| 504 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 505 | th.tableblock.valign-top, td.tableblock.valign-top { |
| 506 | vertical-align: top; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 507 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 508 | th.tableblock.valign-middle, td.tableblock.valign-middle { |
| 509 | vertical-align: middle; |
| 510 | } |
| 511 | th.tableblock.valign-bottom, td.tableblock.valign-bottom { |
| 512 | vertical-align: bottom; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 513 | } |
| 514 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 515 | |
| 516 | /* |
| 517 | * manpage specific |
| 518 | * |
| 519 | * */ |
| 520 | |
| 521 | body.manpage h1 { |
| 522 | padding-top: 0.5em; |
| 523 | padding-bottom: 0.5em; |
| 524 | border-top: 2px solid silver; |
| 525 | border-bottom: 2px solid silver; |
| 526 | } |
| 527 | body.manpage h2 { |
| 528 | border-style: none; |
| 529 | } |
| 530 | body.manpage div.sectionbody { |
| 531 | margin-left: 3em; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 532 | } |
| 533 | |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 534 | @media print { |
| 535 | body.manpage div#toc { display: none; } |
| 536 | } |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 537 | |
| 538 | |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 539 | </style> |
| 540 | <script type="text/javascript"> |
| 541 | /*<![CDATA[*/ |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 542 | var asciidoc = { // Namespace. |
| 543 | |
| 544 | ///////////////////////////////////////////////////////////////////// |
| 545 | // Table Of Contents generator |
| 546 | ///////////////////////////////////////////////////////////////////// |
| 547 | |
| 548 | /* Author: Mihai Bazon, September 2002 |
| 549 | * http://students.infoiasi.ro/~mishoo |
| 550 | * |
| 551 | * Table Of Content generator |
| 552 | * Version: 0.4 |
| 553 | * |
| 554 | * Feel free to use this script under the terms of the GNU General Public |
| 555 | * License, as long as you do not remove or alter this notice. |
| 556 | */ |
| 557 | |
| 558 | /* modified by Troy D. Hanson, September 2006. License: GPL */ |
| 559 | /* modified by Stuart Rackham, 2006, 2009. License: GPL */ |
| 560 | |
| 561 | // toclevels = 1..4. |
| 562 | toc: function (toclevels) { |
| 563 | |
| 564 | function getText(el) { |
| 565 | var text = ""; |
| 566 | for (var i = el.firstChild; i != null; i = i.nextSibling) { |
| 567 | if (i.nodeType == 3 /* Node.TEXT_NODE */) // IE doesn't speak constants. |
| 568 | text += i.data; |
| 569 | else if (i.firstChild != null) |
| 570 | text += getText(i); |
| 571 | } |
| 572 | return text; |
| 573 | } |
| 574 | |
| 575 | function TocEntry(el, text, toclevel) { |
| 576 | this.element = el; |
| 577 | this.text = text; |
| 578 | this.toclevel = toclevel; |
| 579 | } |
| 580 | |
| 581 | function tocEntries(el, toclevels) { |
| 582 | var result = new Array; |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 583 | var re = new RegExp('[hH]([1-'+(toclevels+1)+'])'); |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 584 | // Function that scans the DOM tree for header elements (the DOM2 |
| 585 | // nodeIterator API would be a better technique but not supported by all |
| 586 | // browsers). |
| 587 | var iterate = function (el) { |
| 588 | for (var i = el.firstChild; i != null; i = i.nextSibling) { |
| 589 | if (i.nodeType == 1 /* Node.ELEMENT_NODE */) { |
| 590 | var mo = re.exec(i.tagName); |
| 591 | if (mo && (i.getAttribute("class") || i.getAttribute("className")) != "float") { |
| 592 | result[result.length] = new TocEntry(i, getText(i), mo[1]-1); |
| 593 | } |
| 594 | iterate(i); |
| 595 | } |
| 596 | } |
| 597 | } |
| 598 | iterate(el); |
| 599 | return result; |
| 600 | } |
| 601 | |
| 602 | var toc = document.getElementById("toc"); |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 603 | if (!toc) { |
| 604 | return; |
| 605 | } |
| 606 | |
| 607 | // Delete existing TOC entries in case we're reloading the TOC. |
| 608 | var tocEntriesToRemove = []; |
| 609 | var i; |
| 610 | for (i = 0; i < toc.childNodes.length; i++) { |
| 611 | var entry = toc.childNodes[i]; |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 612 | if (entry.nodeName.toLowerCase() == 'div' |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 613 | && entry.getAttribute("class") |
| 614 | && entry.getAttribute("class").match(/^toclevel/)) |
| 615 | tocEntriesToRemove.push(entry); |
| 616 | } |
| 617 | for (i = 0; i < tocEntriesToRemove.length; i++) { |
| 618 | toc.removeChild(tocEntriesToRemove[i]); |
| 619 | } |
| 620 | |
| 621 | // Rebuild TOC entries. |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 622 | var entries = tocEntries(document.getElementById("content"), toclevels); |
| 623 | for (var i = 0; i < entries.length; ++i) { |
| 624 | var entry = entries[i]; |
| 625 | if (entry.element.id == "") |
| 626 | entry.element.id = "_toc_" + i; |
| 627 | var a = document.createElement("a"); |
| 628 | a.href = "#" + entry.element.id; |
| 629 | a.appendChild(document.createTextNode(entry.text)); |
| 630 | var div = document.createElement("div"); |
| 631 | div.appendChild(a); |
| 632 | div.className = "toclevel" + entry.toclevel; |
| 633 | toc.appendChild(div); |
| 634 | } |
| 635 | if (entries.length == 0) |
| 636 | toc.parentNode.removeChild(toc); |
| 637 | }, |
| 638 | |
| 639 | |
| 640 | ///////////////////////////////////////////////////////////////////// |
| 641 | // Footnotes generator |
| 642 | ///////////////////////////////////////////////////////////////////// |
| 643 | |
| 644 | /* Based on footnote generation code from: |
| 645 | * http://www.brandspankingnew.net/archive/2005/07/format_footnote.html |
| 646 | */ |
| 647 | |
| 648 | footnotes: function () { |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 649 | // Delete existing footnote entries in case we're reloading the footnodes. |
| 650 | var i; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 651 | var noteholder = document.getElementById("footnotes"); |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 652 | if (!noteholder) { |
| 653 | return; |
| 654 | } |
| 655 | var entriesToRemove = []; |
| 656 | for (i = 0; i < noteholder.childNodes.length; i++) { |
| 657 | var entry = noteholder.childNodes[i]; |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 658 | if (entry.nodeName.toLowerCase() == 'div' && entry.getAttribute("class") == "footnote") |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 659 | entriesToRemove.push(entry); |
| 660 | } |
| 661 | for (i = 0; i < entriesToRemove.length; i++) { |
| 662 | noteholder.removeChild(entriesToRemove[i]); |
| 663 | } |
| 664 | |
| 665 | // Rebuild footnote entries. |
| 666 | var cont = document.getElementById("content"); |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 667 | var spans = cont.getElementsByTagName("span"); |
| 668 | var refs = {}; |
| 669 | var n = 0; |
| 670 | for (i=0; i<spans.length; i++) { |
| 671 | if (spans[i].className == "footnote") { |
| 672 | n++; |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 673 | var note = spans[i].getAttribute("data-note"); |
| 674 | if (!note) { |
| 675 | // Use [\s\S] in place of . so multi-line matches work. |
| 676 | // Because JavaScript has no s (dotall) regex flag. |
| 677 | note = spans[i].innerHTML.match(/\s*\[([\s\S]*)]\s*/)[1]; |
| 678 | spans[i].innerHTML = |
| 679 | "[<a id='_footnoteref_" + n + "' href='#_footnote_" + n + |
| 680 | "' title='View footnote' class='footnote'>" + n + "</a>]"; |
| 681 | spans[i].setAttribute("data-note", note); |
| 682 | } |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 683 | noteholder.innerHTML += |
| 684 | "<div class='footnote' id='_footnote_" + n + "'>" + |
| 685 | "<a href='#_footnoteref_" + n + "' title='Return to text'>" + |
| 686 | n + "</a>. " + note + "</div>"; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 687 | var id =spans[i].getAttribute("id"); |
| 688 | if (id != null) refs["#"+id] = n; |
| 689 | } |
| 690 | } |
| 691 | if (n == 0) |
| 692 | noteholder.parentNode.removeChild(noteholder); |
| 693 | else { |
| 694 | // Process footnoterefs. |
| 695 | for (i=0; i<spans.length; i++) { |
| 696 | if (spans[i].className == "footnoteref") { |
| 697 | var href = spans[i].getElementsByTagName("a")[0].getAttribute("href"); |
| 698 | href = href.match(/#.*/)[0]; // Because IE return full URL. |
| 699 | n = refs[href]; |
| 700 | spans[i].innerHTML = |
| 701 | "[<a href='#_footnote_" + n + |
| 702 | "' title='View footnote' class='footnote'>" + n + "</a>]"; |
| 703 | } |
| 704 | } |
| 705 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 706 | }, |
| 707 | |
| 708 | install: function(toclevels) { |
| 709 | var timerId; |
| 710 | |
| 711 | function reinstall() { |
| 712 | asciidoc.footnotes(); |
| 713 | if (toclevels) { |
| 714 | asciidoc.toc(toclevels); |
| 715 | } |
| 716 | } |
| 717 | |
| 718 | function reinstallAndRemoveTimer() { |
| 719 | clearInterval(timerId); |
| 720 | reinstall(); |
| 721 | } |
| 722 | |
| 723 | timerId = setInterval(reinstall, 500); |
| 724 | if (document.addEventListener) |
| 725 | document.addEventListener("DOMContentLoaded", reinstallAndRemoveTimer, false); |
| 726 | else |
| 727 | window.onload = reinstallAndRemoveTimer; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 728 | } |
| 729 | |
| 730 | } |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 731 | asciidoc.install(); |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 732 | /*]]>*/ |
| 733 | </script> |
| 734 | </head> |
Junio C Hamano | 9d97115 | 2012-12-19 00:43:11 | [diff] [blame] | 735 | <body class="article"> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 736 | <div id="header"> |
| 737 | <h1>How to maintain Git</h1> |
| 738 | </div> |
| 739 | <div id="content"> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 740 | <div class="sect1"> |
| 741 | <h2 id="_activities">Activities</h2> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 742 | <div class="sectionbody"> |
Junio C Hamano | 076ffcc | 2013-02-06 05:13:21 | [diff] [blame] | 743 | <div class="paragraph"><p>The maintainer’s Git time is spent on three activities.</p></div> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 744 | <div class="ulist"><ul> |
| 745 | <li> |
| 746 | <p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 747 | Communication (45%) |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 748 | </p> |
| 749 | <div class="literalblock"> |
| 750 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 751 | <pre><code>Mailing list discussions on general design, fielding user |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 752 | questions, diagnosing bug reports; reviewing, commenting on, |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 753 | suggesting alternatives to, and rejecting patches.</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 754 | </div></div> |
| 755 | </li> |
| 756 | <li> |
| 757 | <p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 758 | Integration (50%) |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 759 | </p> |
| 760 | <div class="literalblock"> |
| 761 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 762 | <pre><code>Applying new patches from the contributors while spotting and |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 763 | correcting minor mistakes, shuffling the integration and |
| 764 | testing branches, pushing the results out, cutting the |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 765 | releases, and making announcements.</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 766 | </div></div> |
| 767 | </li> |
| 768 | <li> |
| 769 | <p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 770 | Own development (5%) |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 771 | </p> |
| 772 | <div class="literalblock"> |
| 773 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 774 | <pre><code>Scratching my own itch and sending proposed patch series out.</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 775 | </div></div> |
| 776 | </li> |
| 777 | </ul></div> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 778 | </div> |
| 779 | </div> |
| 780 | <div class="sect1"> |
| 781 | <h2 id="_the_policy">The Policy</h2> |
| 782 | <div class="sectionbody"> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 783 | <div class="paragraph"><p>The policy on Integration is informally mentioned in "A Note |
| 784 | from the maintainer" message, which is periodically posted to |
| 785 | this mailing list after each feature release is made.</p></div> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 786 | <div class="ulist"><ul> |
| 787 | <li> |
| 788 | <p> |
Junio C Hamano | a9c3634 | 2014-02-06 23:33:42 | [diff] [blame] | 789 | Feature releases are numbered as vX.Y.0 and are meant to |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 790 | contain bugfixes and enhancements in any area, including |
| 791 | functionality, performance and usability, without regression. |
| 792 | </p> |
| 793 | </li> |
| 794 | <li> |
| 795 | <p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 796 | One release cycle for a feature release is expected to last for |
| 797 | eight to ten weeks. |
| 798 | </p> |
| 799 | </li> |
| 800 | <li> |
| 801 | <p> |
Junio C Hamano | a9c3634 | 2014-02-06 23:33:42 | [diff] [blame] | 802 | Maintenance releases are numbered as vX.Y.Z and are meant |
| 803 | to contain only bugfixes for the corresponding vX.Y.0 feature |
| 804 | release and earlier maintenance releases vX.Y.W (W < Z). |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 805 | </p> |
| 806 | </li> |
| 807 | <li> |
| 808 | <p> |
| 809 | <em>master</em> branch is used to prepare for the next feature |
| 810 | release. In other words, at some point, the tip of <em>master</em> |
Junio C Hamano | a9c3634 | 2014-02-06 23:33:42 | [diff] [blame] | 811 | branch is tagged with vX.Y.0. |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 812 | </p> |
| 813 | </li> |
| 814 | <li> |
| 815 | <p> |
| 816 | <em>maint</em> branch is used to prepare for the next maintenance |
Junio C Hamano | a9c3634 | 2014-02-06 23:33:42 | [diff] [blame] | 817 | release. After the feature release vX.Y.0 is made, the tip |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 818 | of <em>maint</em> branch is set to that release, and bugfixes will |
| 819 | accumulate on the branch, and at some point, the tip of the |
Junio C Hamano | a9c3634 | 2014-02-06 23:33:42 | [diff] [blame] | 820 | branch is tagged with vX.Y.1, vX.Y.2, and so on. |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 821 | </p> |
| 822 | </li> |
| 823 | <li> |
| 824 | <p> |
| 825 | <em>next</em> branch is used to publish changes (both enhancements |
| 826 | and fixes) that (1) have worthwhile goal, (2) are in a fairly |
| 827 | good shape suitable for everyday use, (3) but have not yet |
| 828 | demonstrated to be regression free. New changes are tested |
| 829 | in <em>next</em> before merged to <em>master</em>. |
| 830 | </p> |
| 831 | </li> |
| 832 | <li> |
| 833 | <p> |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 834 | <em>seen</em> branch is used to publish other proposed changes that do |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 835 | not yet pass the criteria set for <em>next</em>. |
| 836 | </p> |
| 837 | </li> |
| 838 | <li> |
| 839 | <p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 840 | The tips of <em>master</em> and <em>maint</em> branches will not be rewound to |
| 841 | allow people to build their own customization on top of them. |
| 842 | Early in a new development cycle, <em>next</em> is rewound to the tip of |
| 843 | <em>master</em> once, but otherwise it will not be rewound until the end |
| 844 | of the cycle. |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 845 | </p> |
| 846 | </li> |
| 847 | <li> |
| 848 | <p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 849 | Usually <em>master</em> contains all of <em>maint</em> and <em>next</em> contains all |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 850 | of <em>master</em>. <em>seen</em> contains all the topics merged to <em>next</em>, but |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 851 | is rebuilt directly on <em>master</em>. |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 852 | </p> |
| 853 | </li> |
| 854 | <li> |
| 855 | <p> |
| 856 | The tip of <em>master</em> is meant to be more stable than any |
| 857 | tagged releases, and the users are encouraged to follow it. |
| 858 | </p> |
| 859 | </li> |
| 860 | <li> |
| 861 | <p> |
| 862 | The <em>next</em> branch is where new action takes place, and the |
| 863 | users are encouraged to test it so that regressions and bugs |
| 864 | are found before new topics are merged to <em>master</em>. |
| 865 | </p> |
| 866 | </li> |
| 867 | </ul></div> |
Junio C Hamano | a9c3634 | 2014-02-06 23:33:42 | [diff] [blame] | 868 | <div class="paragraph"><p>Note that before v1.9.0 release, the version numbers used to be |
| 869 | structured slightly differently. vX.Y.Z were feature releases while |
| 870 | vX.Y.Z.W were maintenance releases for vX.Y.Z.</p></div> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 871 | </div> |
| 872 | </div> |
| 873 | <div class="sect1"> |
| 874 | <h2 id="_a_typical_git_day">A Typical Git Day</h2> |
| 875 | <div class="sectionbody"> |
Junio C Hamano | 076ffcc | 2013-02-06 05:13:21 | [diff] [blame] | 876 | <div class="paragraph"><p>A typical Git day for the maintainer implements the above policy |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 877 | by doing the following:</p></div> |
| 878 | <div class="ulist"><ul> |
| 879 | <li> |
| 880 | <p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 881 | Scan mailing list. Respond with review comments, suggestions |
| 882 | etc. Kibitz. Collect potentially usable patches from the |
| 883 | mailing list. Patches about a single topic go to one mailbox (I |
| 884 | read my mail in Gnus, and type \C-o to save/append messages in |
| 885 | files in mbox format). |
| 886 | </p> |
| 887 | </li> |
| 888 | <li> |
| 889 | <p> |
| 890 | Write his own patches to address issues raised on the list but |
| 891 | nobody has stepped up solving. Send it out just like other |
| 892 | contributors do, and pick them up just like patches from other |
| 893 | contributors (see above). |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 894 | </p> |
| 895 | </li> |
| 896 | <li> |
| 897 | <p> |
| 898 | Review the patches in the saved mailboxes. Edit proposed log |
| 899 | message for typofixes and clarifications, and add Acks |
| 900 | collected from the list. Edit patch to incorporate "Oops, |
| 901 | that should have been like this" fixes from the discussion. |
| 902 | </p> |
| 903 | </li> |
| 904 | <li> |
| 905 | <p> |
| 906 | Classify the collected patches and handle <em>master</em> and |
| 907 | <em>maint</em> updates: |
| 908 | </p> |
| 909 | </li> |
| 910 | <li> |
| 911 | <p> |
| 912 | Obviously correct fixes that pertain to the tip of <em>maint</em> |
| 913 | are directly applied to <em>maint</em>. |
| 914 | </p> |
| 915 | </li> |
| 916 | <li> |
| 917 | <p> |
| 918 | Obviously correct fixes that pertain to the tip of <em>master</em> |
| 919 | are directly applied to <em>master</em>. |
| 920 | </p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 921 | </li> |
| 922 | <li> |
| 923 | <p> |
| 924 | Other topics are not handled in this step. |
| 925 | </p> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 926 | <div class="literalblock"> |
| 927 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 928 | <pre><code>This step is done with "git am".</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 929 | </div></div> |
| 930 | <div class="literalblock"> |
| 931 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 932 | <pre><code>$ git checkout master ;# or "git checkout maint" |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 933 | $ git am -sc3 mailbox |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 934 | $ make test</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 935 | </div></div> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 936 | <div class="literalblock"> |
| 937 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 938 | <pre><code>In practice, almost no patch directly goes to 'master' or |
| 939 | 'maint'.</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 940 | </div></div> |
| 941 | </li> |
| 942 | <li> |
| 943 | <p> |
| 944 | Review the last issue of "What’s cooking" message, review the |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 945 | topics ready for merging (topic→master and topic→maint). Use |
| 946 | "Meta/cook -w" script (where Meta/ contains a checkout of the |
| 947 | <em>todo</em> branch) to aid this step. |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 948 | </p> |
| 949 | <div class="literalblock"> |
| 950 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 951 | <pre><code>And perform the merge. Use "Meta/Reintegrate -e" script (see |
| 952 | later) to aid this step.</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 953 | </div></div> |
| 954 | <div class="literalblock"> |
| 955 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 956 | <pre><code>$ Meta/cook -w last-issue-of-whats-cooking.mbox</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 957 | </div></div> |
| 958 | <div class="literalblock"> |
| 959 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 960 | <pre><code>$ git checkout master ;# or "git checkout maint" |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 961 | $ echo ai/topic | Meta/Reintegrate -e ;# "git merge ai/topic" |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 962 | $ git log -p ORIG_HEAD.. ;# final review |
| 963 | $ git diff ORIG_HEAD.. ;# final review |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 964 | $ make test ;# final review</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 965 | </div></div> |
| 966 | </li> |
| 967 | <li> |
| 968 | <p> |
| 969 | Handle the remaining patches: |
| 970 | </p> |
| 971 | </li> |
| 972 | <li> |
| 973 | <p> |
| 974 | Anything unobvious that is applicable to <em>master</em> (in other |
| 975 | words, does not depend on anything that is still in <em>next</em> |
| 976 | and not in <em>master</em>) is applied to a new topic branch that |
Junio C Hamano | 357906b | 2020-03-25 21:32:01 | [diff] [blame] | 977 | is forked from the tip of <em>master</em> (or the last feature release, |
| 978 | which is a bit older than <em>master</em>). This includes both |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 979 | enhancements and unobvious fixes to <em>master</em>. A topic |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 980 | branch is named as ai/topic where "ai" is two-letter string |
| 981 | named after author’s initial and "topic" is a descriptive name |
| 982 | of the topic (in other words, "what’s the series is about"). |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 983 | </p> |
| 984 | </li> |
| 985 | <li> |
| 986 | <p> |
| 987 | An unobvious fix meant for <em>maint</em> is applied to a new |
Junio C Hamano | 357906b | 2020-03-25 21:32:01 | [diff] [blame] | 988 | topic branch that is forked from the tip of <em>maint</em> (or the |
| 989 | oldest and still relevant maintenance branch). The |
| 990 | topic may be named as ai/maint-topic. |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 991 | </p> |
| 992 | </li> |
| 993 | <li> |
| 994 | <p> |
| 995 | Changes that pertain to an existing topic are applied to |
| 996 | the branch, but: |
| 997 | </p> |
| 998 | </li> |
| 999 | <li> |
| 1000 | <p> |
| 1001 | obviously correct ones are applied first; |
| 1002 | </p> |
| 1003 | </li> |
| 1004 | <li> |
| 1005 | <p> |
| 1006 | questionable ones are discarded or applied to near the tip; |
| 1007 | </p> |
| 1008 | </li> |
| 1009 | <li> |
| 1010 | <p> |
| 1011 | Replacement patches to an existing topic are accepted only |
| 1012 | for commits not in <em>next</em>. |
| 1013 | </p> |
| 1014 | <div class="literalblock"> |
| 1015 | <div class="content"> |
Junio C Hamano | 357906b | 2020-03-25 21:32:01 | [diff] [blame] | 1016 | <pre><code>The initial round is done with:</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1017 | </div></div> |
| 1018 | <div class="literalblock"> |
| 1019 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1020 | <pre><code>$ git checkout ai/topic ;# or "git checkout -b ai/topic master" |
| 1021 | $ git am -sc3 mailbox</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1022 | </div></div> |
| 1023 | <div class="literalblock"> |
| 1024 | <div class="content"> |
Junio C Hamano | 357906b | 2020-03-25 21:32:01 | [diff] [blame] | 1025 | <pre><code>and replacing an existing topic with subsequent round is done with:</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1026 | </div></div> |
| 1027 | <div class="literalblock"> |
| 1028 | <div class="content"> |
Junio C Hamano | 357906b | 2020-03-25 21:32:01 | [diff] [blame] | 1029 | <pre><code>$ git checkout master...ai/topic ;# try to reapply to the same base |
| 1030 | $ git am -sc3 mailbox</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1031 | </div></div> |
| 1032 | <div class="literalblock"> |
| 1033 | <div class="content"> |
Junio C Hamano | 357906b | 2020-03-25 21:32:01 | [diff] [blame] | 1034 | <pre><code>to prepare the new round on a detached HEAD, and then</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1035 | </div></div> |
| 1036 | <div class="literalblock"> |
| 1037 | <div class="content"> |
Junio C Hamano | 357906b | 2020-03-25 21:32:01 | [diff] [blame] | 1038 | <pre><code>$ git range-diff @{-1}... |
| 1039 | $ git diff @{-1}</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1040 | </div></div> |
| 1041 | <div class="literalblock"> |
| 1042 | <div class="content"> |
Junio C Hamano | 357906b | 2020-03-25 21:32:01 | [diff] [blame] | 1043 | <pre><code>to double check what changed since the last round, and finally</code></pre> |
| 1044 | </div></div> |
| 1045 | <div class="literalblock"> |
| 1046 | <div class="content"> |
| 1047 | <pre><code>$ git checkout -B @{-1}</code></pre> |
| 1048 | </div></div> |
| 1049 | <div class="literalblock"> |
| 1050 | <div class="content"> |
| 1051 | <pre><code>to conclude (the last step is why a topic already in 'next' is |
| 1052 | not replaced but updated incrementally).</code></pre> |
| 1053 | </div></div> |
| 1054 | <div class="literalblock"> |
| 1055 | <div class="content"> |
| 1056 | <pre><code>Whether it is the initial round or a subsequent round, the topic |
| 1057 | may not build even in isolation, or may break the build when |
| 1058 | merged to integration branches due to bugs. There may already |
| 1059 | be obvious and trivial improvements suggested on the list. The |
| 1060 | maintainer often adds an extra commit, with "SQUASH???" in its |
| 1061 | title, to fix things up, before publishing the integration |
| 1062 | branches to make it usable by other developers for testing. |
| 1063 | These changes are what the maintainer is not 100% committed to |
| 1064 | (trivial typofixes etc. are often squashed directly into the |
| 1065 | patches that need fixing, without being applied as a separate |
| 1066 | "SQUASH???" commit), so that they can be removed easily as needed.</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1067 | </div></div> |
| 1068 | </li> |
| 1069 | <li> |
| 1070 | <p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1071 | Merge maint to master as needed: |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1072 | </p> |
| 1073 | <div class="literalblock"> |
| 1074 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1075 | <pre><code>$ git checkout master |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1076 | $ git merge maint |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1077 | $ make test</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1078 | </div></div> |
| 1079 | </li> |
| 1080 | <li> |
| 1081 | <p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1082 | Merge master to next as needed: |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1083 | </p> |
| 1084 | <div class="literalblock"> |
| 1085 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1086 | <pre><code>$ git checkout next |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1087 | $ git merge master |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1088 | $ make test</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1089 | </div></div> |
| 1090 | </li> |
| 1091 | <li> |
| 1092 | <p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1093 | Review the last issue of "What’s cooking" again and see if topics |
| 1094 | that are ready to be merged to <em>next</em> are still in good shape |
| 1095 | (e.g. has there any new issue identified on the list with the |
| 1096 | series?) |
| 1097 | </p> |
| 1098 | </li> |
| 1099 | <li> |
| 1100 | <p> |
| 1101 | Prepare <em>jch</em> branch, which is used to represent somewhere |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1102 | between <em>master</em> and <em>seen</em> and often is slightly ahead of <em>next</em>. |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1103 | </p> |
| 1104 | <div class="literalblock"> |
| 1105 | <div class="content"> |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1106 | <pre><code>$ Meta/Reintegrate master..seen >Meta/redo-jch.sh</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1107 | </div></div> |
| 1108 | <div class="literalblock"> |
| 1109 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1110 | <pre><code>The result is a script that lists topics to be merged in order to |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1111 | rebuild 'seen' as the input to Meta/Reintegrate script. Remove |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1112 | later topics that should not be in 'jch' yet. Add a line that |
| 1113 | consists of '### match next' before the name of the first topic |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1114 | in the output that should be in 'jch' but not in 'next' yet.</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1115 | </div></div> |
| 1116 | </li> |
| 1117 | <li> |
| 1118 | <p> |
| 1119 | Now we are ready to start merging topics to <em>next</em>. For each |
| 1120 | branch whose tip is not merged to <em>next</em>, one of three things can |
| 1121 | happen: |
| 1122 | </p> |
| 1123 | </li> |
| 1124 | <li> |
| 1125 | <p> |
| 1126 | The commits are all next-worthy; merge the topic to next; |
| 1127 | </p> |
| 1128 | </li> |
| 1129 | <li> |
| 1130 | <p> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1131 | The new parts are of mixed quality, but earlier ones are |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1132 | next-worthy; merge the early parts to next; |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1133 | </p> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1134 | </li> |
| 1135 | <li> |
| 1136 | <p> |
| 1137 | Nothing is next-worthy; do not do anything. |
| 1138 | </p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1139 | <div class="literalblock"> |
| 1140 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1141 | <pre><code>This step is aided with Meta/redo-jch.sh script created earlier. |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1142 | If a topic that was already in 'next' gained a patch, the script |
| 1143 | would list it as "ai/topic~1". To include the new patch to the |
| 1144 | updated 'next', drop the "~1" part; to keep it excluded, do not |
| 1145 | touch the line. If a topic that was not in 'next' should be |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1146 | merged to 'next', add it at the end of the list. Then:</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1147 | </div></div> |
| 1148 | <div class="literalblock"> |
| 1149 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1150 | <pre><code>$ git checkout -B jch master |
| 1151 | $ Meta/redo-jch.sh -c1</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1152 | </div></div> |
| 1153 | <div class="literalblock"> |
| 1154 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1155 | <pre><code>to rebuild the 'jch' branch from scratch. "-c1" tells the script |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1156 | to stop merging at the first line that begins with '###' |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1157 | (i.e. the "### match next" line you added earlier).</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1158 | </div></div> |
| 1159 | <div class="literalblock"> |
| 1160 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1161 | <pre><code>At this point, build-test the result. It may reveal semantic |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1162 | conflicts (e.g. a topic renamed a variable, another added a new |
| 1163 | reference to the variable under its old name), in which case |
| 1164 | prepare an appropriate merge-fix first (see appendix), and |
| 1165 | rebuild the 'jch' branch from scratch, starting at the tip of |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1166 | 'master'.</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1167 | </div></div> |
| 1168 | <div class="literalblock"> |
| 1169 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1170 | <pre><code>Then do the same to 'next'</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1171 | </div></div> |
| 1172 | <div class="literalblock"> |
| 1173 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1174 | <pre><code>$ git checkout next |
| 1175 | $ sh Meta/redo-jch.sh -c1 -e</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1176 | </div></div> |
| 1177 | <div class="literalblock"> |
| 1178 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1179 | <pre><code>The "-e" option allows the merge message that comes from the |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1180 | history of the topic and the comments in the "What's cooking" to |
| 1181 | be edited. The resulting tree should match 'jch' as the same set |
| 1182 | of topics are merged on 'master'; otherwise there is a mismerge. |
| 1183 | Investigate why and do not proceed until the mismerge is found |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1184 | and rectified.</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1185 | </div></div> |
| 1186 | <div class="literalblock"> |
| 1187 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1188 | <pre><code>$ git diff jch next</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1189 | </div></div> |
| 1190 | <div class="literalblock"> |
| 1191 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1192 | <pre><code>When all is well, clean up the redo-jch.sh script with</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1193 | </div></div> |
| 1194 | <div class="literalblock"> |
| 1195 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1196 | <pre><code>$ sh Meta/redo-jch.sh -u</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1197 | </div></div> |
| 1198 | <div class="literalblock"> |
| 1199 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1200 | <pre><code>This removes topics listed in the script that have already been |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1201 | merged to 'master'. This may lose '### match next' marker; |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1202 | add it again to the appropriate place when it happens.</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1203 | </div></div> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1204 | </li> |
| 1205 | <li> |
| 1206 | <p> |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1207 | Rebuild <em>seen</em>. |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1208 | </p> |
| 1209 | <div class="literalblock"> |
| 1210 | <div class="content"> |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1211 | <pre><code>$ Meta/Reintegrate master..seen >Meta/redo-seen.sh</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1212 | </div></div> |
| 1213 | <div class="literalblock"> |
| 1214 | <div class="content"> |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1215 | <pre><code>Edit the result by adding new topics that are not still in 'seen' |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1216 | in the script. Then</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1217 | </div></div> |
| 1218 | <div class="literalblock"> |
| 1219 | <div class="content"> |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1220 | <pre><code>$ git checkout -B seen jch |
| 1221 | $ sh Meta/redo-seen.sh</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1222 | </div></div> |
| 1223 | <div class="literalblock"> |
| 1224 | <div class="content"> |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1225 | <pre><code>When all is well, clean up the redo-seen.sh script with</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1226 | </div></div> |
| 1227 | <div class="literalblock"> |
| 1228 | <div class="content"> |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1229 | <pre><code>$ sh Meta/redo-seen.sh -u</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1230 | </div></div> |
| 1231 | <div class="literalblock"> |
| 1232 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1233 | <pre><code>Double check by running</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1234 | </div></div> |
| 1235 | <div class="literalblock"> |
| 1236 | <div class="content"> |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1237 | <pre><code>$ git branch --no-merged seen</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1238 | </div></div> |
| 1239 | <div class="literalblock"> |
| 1240 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1241 | <pre><code>to see there is no unexpected leftover topics.</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1242 | </div></div> |
| 1243 | <div class="literalblock"> |
| 1244 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1245 | <pre><code>At this point, build-test the result for semantic conflicts, and |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1246 | if there are, prepare an appropriate merge-fix first (see |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1247 | appendix), and rebuild the 'seen' branch from scratch, starting at |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1248 | the tip of 'jch'.</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1249 | </div></div> |
| 1250 | </li> |
| 1251 | <li> |
| 1252 | <p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1253 | Update "What’s cooking" message to review the updates to |
| 1254 | existing topics, newly added topics and graduated topics. |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1255 | </p> |
| 1256 | <div class="literalblock"> |
| 1257 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1258 | <pre><code>This step is helped with Meta/cook script.</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1259 | </div></div> |
| 1260 | <div class="literalblock"> |
| 1261 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1262 | <pre><code>$ Meta/cook</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1263 | </div></div> |
| 1264 | <div class="literalblock"> |
| 1265 | <div class="content"> |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1266 | <pre><code>This script inspects the history between master..seen, finds tips |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1267 | of topic branches, compares what it found with the current |
| 1268 | contents in Meta/whats-cooking.txt, and updates that file. |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1269 | Topics not listed in the file but are found in master..seen are |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1270 | added to the "New topics" section, topics listed in the file that |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1271 | are no longer found in master..seen are moved to the "Graduated to |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1272 | master" section, and topics whose commits changed their states |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1273 | (e.g. used to be only in 'seen', now merged to 'next') are updated |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1274 | with change markers "<<" and ">>".</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1275 | </div></div> |
| 1276 | <div class="literalblock"> |
| 1277 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1278 | <pre><code>Look for lines enclosed in "<<" and ">>"; they hold contents from |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1279 | old file that are replaced by this integration round. After |
| 1280 | verifying them, remove the old part. Review the description for |
| 1281 | each topic and update its doneness and plan as needed. To review |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1282 | the updated plan, run</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1283 | </div></div> |
| 1284 | <div class="literalblock"> |
| 1285 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1286 | <pre><code>$ Meta/cook -w</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1287 | </div></div> |
| 1288 | <div class="literalblock"> |
| 1289 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1290 | <pre><code>which will pick up comments given to the topics, such as "Will |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1291 | merge to 'next'", etc. (see Meta/cook script to learn what kind |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1292 | of phrases are supported).</code></pre> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1293 | </div></div> |
| 1294 | </li> |
| 1295 | <li> |
| 1296 | <p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1297 | Compile, test and install all four (five) integration branches; |
| 1298 | Meta/Dothem script may aid this step. |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1299 | </p> |
| 1300 | </li> |
| 1301 | <li> |
| 1302 | <p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1303 | Format documentation if the <em>master</em> branch was updated; |
| 1304 | Meta/dodoc.sh script may aid this step. |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1305 | </p> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1306 | </li> |
| 1307 | <li> |
| 1308 | <p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1309 | Push the integration branches out to public places; Meta/pushall |
| 1310 | script may aid this step. |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1311 | </p> |
| 1312 | </li> |
| 1313 | </ul></div> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1314 | </div> |
| 1315 | </div> |
| 1316 | <div class="sect1"> |
| 1317 | <h2 id="_observations">Observations</h2> |
| 1318 | <div class="sectionbody"> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1319 | <div class="paragraph"><p>Some observations to be made.</p></div> |
| 1320 | <div class="ulist"><ul> |
| 1321 | <li> |
| 1322 | <p> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1323 | Each topic is tested individually, and also together with other |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1324 | topics cooking first in <em>seen</em>, then in <em>jch</em> and then in <em>next</em>. |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1325 | Until it matures, no part of it is merged to <em>master</em>. |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1326 | </p> |
| 1327 | </li> |
| 1328 | <li> |
| 1329 | <p> |
| 1330 | A topic already in <em>next</em> can get fixes while still in |
| 1331 | <em>next</em>. Such a topic will have many merges to <em>next</em> (in |
| 1332 | other words, "git log --first-parent next" will show many |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1333 | "Merge branch <em>ai/topic</em> to next" for the same topic. |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1334 | </p> |
| 1335 | </li> |
| 1336 | <li> |
| 1337 | <p> |
| 1338 | An unobvious fix for <em>maint</em> is cooked in <em>next</em> and then |
| 1339 | merged to <em>master</em> to make extra sure it is Ok and then |
| 1340 | merged to <em>maint</em>. |
| 1341 | </p> |
| 1342 | </li> |
| 1343 | <li> |
| 1344 | <p> |
| 1345 | Even when <em>next</em> becomes empty (in other words, all topics |
| 1346 | prove stable and are merged to <em>master</em> and "git diff master |
| 1347 | next" shows empty), it has tons of merge commits that will |
| 1348 | never be in <em>master</em>. |
| 1349 | </p> |
| 1350 | </li> |
| 1351 | <li> |
| 1352 | <p> |
| 1353 | In principle, "git log --first-parent master..next" should |
| 1354 | show nothing but merges (in practice, there are fixup commits |
| 1355 | and reverts that are not merges). |
| 1356 | </p> |
| 1357 | </li> |
| 1358 | <li> |
| 1359 | <p> |
| 1360 | Commits near the tip of a topic branch that are not in <em>next</em> |
| 1361 | are fair game to be discarded, replaced or rewritten. |
| 1362 | Commits already merged to <em>next</em> will not be. |
| 1363 | </p> |
| 1364 | </li> |
| 1365 | <li> |
| 1366 | <p> |
| 1367 | Being in the <em>next</em> branch is not a guarantee for a topic to |
| 1368 | be included in the next feature release. Being in the |
| 1369 | <em>master</em> branch typically is. |
| 1370 | </p> |
| 1371 | </li> |
Junio C Hamano | 357906b | 2020-03-25 21:32:01 | [diff] [blame] | 1372 | <li> |
| 1373 | <p> |
| 1374 | Due to the nature of "SQUASH???" fix-ups, if the original author |
| 1375 | agrees with the suggested changes, it is OK to squash them to |
| 1376 | appropriate patches in the next round (when the suggested change |
| 1377 | is small enough, the author should not even bother with |
| 1378 | "Helped-by"). It is also OK to drop them from the next round |
| 1379 | when the original author does not agree with the suggestion, but |
| 1380 | the author is expected to say why somewhere in the discussion. |
| 1381 | </p> |
| 1382 | </li> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1383 | </ul></div> |
| 1384 | </div> |
| 1385 | </div> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1386 | <div class="sect1"> |
| 1387 | <h2 id="_appendix">Appendix</h2> |
| 1388 | <div class="sectionbody"> |
| 1389 | <div class="sect2"> |
| 1390 | <h3 id="_preparing_a_merge_fix">Preparing a "merge-fix"</h3> |
| 1391 | <div class="paragraph"><p>A merge of two topics may not textually conflict but still have |
| 1392 | conflict at the semantic level. A classic example is for one topic |
| 1393 | to rename an variable and all its uses, while another topic adds a |
| 1394 | new use of the variable under its old name. When these two topics |
| 1395 | are merged together, the reference to the variable newly added by |
| 1396 | the latter topic will still use the old name in the result.</p></div> |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1397 | <div class="paragraph"><p>The Meta/Reintegrate script that is used by redo-jch and redo-seen |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1398 | scripts implements a crude but usable way to work this issue around. |
| 1399 | When the script merges branch $X, it checks if "refs/merge-fix/$X" |
| 1400 | exists, and if so, the effect of it is squashed into the result of |
| 1401 | the mechanical merge. In other words,</p></div> |
| 1402 | <div class="literalblock"> |
| 1403 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1404 | <pre><code>$ echo $X | Meta/Reintegrate</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1405 | </div></div> |
| 1406 | <div class="paragraph"><p>is roughly equivalent to this sequence:</p></div> |
| 1407 | <div class="literalblock"> |
| 1408 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1409 | <pre><code>$ git merge --rerere-autoupdate $X |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1410 | $ git commit |
| 1411 | $ git cherry-pick -n refs/merge-fix/$X |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1412 | $ git commit --amend</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1413 | </div></div> |
| 1414 | <div class="paragraph"><p>The goal of this "prepare a merge-fix" step is to come up with a |
| 1415 | commit that can be squashed into a result of mechanical merge to |
| 1416 | correct semantic conflicts.</p></div> |
| 1417 | <div class="paragraph"><p>After finding that the result of merging branch "ai/topic" to an |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1418 | integration branch had such a semantic conflict, say seen~4, check the |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1419 | problematic merge out on a detached HEAD, edit the working tree to |
| 1420 | fix the semantic conflict, and make a separate commit to record the |
| 1421 | fix-up:</p></div> |
| 1422 | <div class="literalblock"> |
| 1423 | <div class="content"> |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1424 | <pre><code>$ git checkout seen~4 |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1425 | $ git show -s --pretty=%s ;# double check |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1426 | Merge branch 'ai/topic' to seen |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1427 | $ edit |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1428 | $ git commit -m 'merge-fix/ai/topic' -a</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1429 | </div></div> |
| 1430 | <div class="paragraph"><p>Then make a reference "refs/merge-fix/ai/topic" to point at this |
| 1431 | result:</p></div> |
| 1432 | <div class="literalblock"> |
| 1433 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1434 | <pre><code>$ git update-ref refs/merge-fix/ai/topic HEAD</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1435 | </div></div> |
| 1436 | <div class="paragraph"><p>Then double check the result by asking Meta/Reintegrate to redo the |
| 1437 | merge:</p></div> |
| 1438 | <div class="literalblock"> |
| 1439 | <div class="content"> |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1440 | <pre><code>$ git checkout seen~5 ;# the parent of the problem merge |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1441 | $ echo ai/topic | Meta/Reintegrate |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1442 | $ git diff seen~4</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1443 | </div></div> |
| 1444 | <div class="paragraph"><p>This time, because you prepared refs/merge-fix/ai/topic, the |
| 1445 | resulting merge should have been tweaked to include the fix for the |
| 1446 | semantic conflict.</p></div> |
| 1447 | <div class="paragraph"><p>Note that this assumes that the order in which conflicting branches |
| 1448 | are merged does not change. If the reason why merging ai/topic |
| 1449 | branch needs this merge-fix is because another branch merged earlier |
| 1450 | to the integration branch changed the underlying assumption ai/topic |
| 1451 | branch made (e.g. ai/topic branch added a site to refer to a |
| 1452 | variable, while the other branch renamed that variable and adjusted |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1453 | existing use sites), and if you changed redo-jch (or redo-seen) script |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1454 | to merge ai/topic branch before the other branch, then the above |
| 1455 | merge-fix should not be applied while merging ai/topic, but should |
| 1456 | instead be applied while merging the other branch. You would need |
| 1457 | to move the fix to apply to the other branch, perhaps like this:</p></div> |
| 1458 | <div class="literalblock"> |
| 1459 | <div class="content"> |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1460 | <pre><code>$ mf=refs/merge-fix |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1461 | $ git update-ref $mf/$the_other_branch $mf/ai/topic |
Junio C Hamano | c14e6ad | 2014-10-31 20:25:53 | [diff] [blame] | 1462 | $ git update-ref -d $mf/ai/topic</code></pre> |
Junio C Hamano | 36d5229 | 2013-01-25 21:32:36 | [diff] [blame] | 1463 | </div></div> |
| 1464 | </div> |
| 1465 | </div> |
| 1466 | </div> |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1467 | </div> |
| 1468 | <div id="footnotes"><hr /></div> |
| 1469 | <div id="footer"> |
| 1470 | <div id="footer-text"> |
Junio C Hamano | 2ef0ba3 | 2018-01-26 23:13:53 | [diff] [blame] | 1471 | Last updated |
Junio C Hamano | a891178 | 2020-07-07 05:35:57 | [diff] [blame^] | 1472 | 2020-07-06 22:34:12 PDT |
Junio C Hamano | f2b7494 | 2012-11-20 21:06:26 | [diff] [blame] | 1473 | </div> |
| 1474 | </div> |
| 1475 | </body> |
| 1476 | </html> |