1git(1) 2====== 3 4NAME 5---- 6git - the stupid content tracker 7 8 9SYNOPSIS 10-------- 11[verse] 12'git' [--version] [--help] [-C <path>] [-c <name>=<value>] 13 [--exec-path[=<path>]] [--html-path] [--man-path] [--info-path] 14 [-p|--paginate|--no-pager] [--no-replace-objects] [--bare] 15 [--git-dir=<path>] [--work-tree=<path>] [--namespace=<name>] 16 [--super-prefix=<path>] 17 <command> [<args>] 18 19DESCRIPTION 20----------- 21Git is a fast, scalable, distributed revision control system with an 22unusually rich command set that provides both high-level operations 23and full access to internals. 24 25See linkgit:gittutorial[7] to get started, then see 26linkgit:giteveryday[7] for a useful minimum set of 27commands. The link:user-manual.html[Git User's Manual] has a more 28in-depth introduction. 29 30After you mastered the basic concepts, you can come back to this 31page to learn what commands Git offers. You can learn more about 32individual Git commands with "git help command". linkgit:gitcli[7] 33manual page gives you an overview of the command-line command syntax. 34 35A formatted and hyperlinked copy of the latest Git documentation 36can be viewed at `https://git.github.io/htmldocs/git.html`. 37 38ifdef::stalenotes[] 39[NOTE] 40============ 41 42You are reading the documentation for the latest (possibly 43unreleased) version of Git, that is available from the 'master' 44branch of the `git.git` repository. 45Documentation for older releases are available here: 46 47* link:v2.10.2/git.html[documentation for release 2.10.2] 48 49* release notes for 50 link:RelNotes/2.10.2.txt[2.10.2], 51 link:RelNotes/2.10.1.txt[2.10.1], 52 link:RelNotes/2.10.0.txt[2.10]. 53 54* link:v2.9.3/git.html[documentation for release 2.9.3] 55 56* release notes for 57 link:RelNotes/2.9.3.txt[2.9.3], 58 link:RelNotes/2.9.2.txt[2.9.2], 59 link:RelNotes/2.9.1.txt[2.9.1], 60 link:RelNotes/2.9.0.txt[2.9]. 61 62* link:v2.8.4/git.html[documentation for release 2.8.4] 63 64* release notes for 65 link:RelNotes/2.8.4.txt[2.8.4], 66 link:RelNotes/2.8.3.txt[2.8.3], 67 link:RelNotes/2.8.2.txt[2.8.2], 68 link:RelNotes/2.8.1.txt[2.8.1], 69 link:RelNotes/2.8.0.txt[2.8]. 70 71* link:v2.7.3/git.html[documentation for release 2.7.3] 72 73* release notes for 74 link:RelNotes/2.7.3.txt[2.7.3], 75 link:RelNotes/2.7.2.txt[2.7.2], 76 link:RelNotes/2.7.1.txt[2.7.1], 77 link:RelNotes/2.7.0.txt[2.7]. 78 79* link:v2.6.6/git.html[documentation for release 2.6.6] 80 81* release notes for 82 link:RelNotes/2.6.6.txt[2.6.6], 83 link:RelNotes/2.6.5.txt[2.6.5], 84 link:RelNotes/2.6.4.txt[2.6.4], 85 link:RelNotes/2.6.3.txt[2.6.3], 86 link:RelNotes/2.6.2.txt[2.6.2], 87 link:RelNotes/2.6.1.txt[2.6.1], 88 link:RelNotes/2.6.0.txt[2.6]. 89 90* link:v2.5.5/git.html[documentation for release 2.5.5] 91 92* release notes for 93 link:RelNotes/2.5.5.txt[2.5.5], 94 link:RelNotes/2.5.4.txt[2.5.4], 95 link:RelNotes/2.5.3.txt[2.5.3], 96 link:RelNotes/2.5.2.txt[2.5.2], 97 link:RelNotes/2.5.1.txt[2.5.1], 98 link:RelNotes/2.5.0.txt[2.5]. 99 100* link:v2.4.11/git.html[documentation for release 2.4.11] 101 102* release notes for 103 link:RelNotes/2.4.11.txt[2.4.11], 104 link:RelNotes/2.4.10.txt[2.4.10], 105 link:RelNotes/2.4.9.txt[2.4.9], 106 link:RelNotes/2.4.8.txt[2.4.8], 107 link:RelNotes/2.4.7.txt[2.4.7], 108 link:RelNotes/2.4.6.txt[2.4.6], 109 link:RelNotes/2.4.5.txt[2.4.5], 110 link:RelNotes/2.4.4.txt[2.4.4], 111 link:RelNotes/2.4.3.txt[2.4.3], 112 link:RelNotes/2.4.2.txt[2.4.2], 113 link:RelNotes/2.4.1.txt[2.4.1], 114 link:RelNotes/2.4.0.txt[2.4]. 115 116* link:v2.3.10/git.html[documentation for release 2.3.10] 117 118* release notes for 119 link:RelNotes/2.3.10.txt[2.3.10], 120 link:RelNotes/2.3.9.txt[2.3.9], 121 link:RelNotes/2.3.8.txt[2.3.8], 122 link:RelNotes/2.3.7.txt[2.3.7], 123 link:RelNotes/2.3.6.txt[2.3.6], 124 link:RelNotes/2.3.5.txt[2.3.5], 125 link:RelNotes/2.3.4.txt[2.3.4], 126 link:RelNotes/2.3.3.txt[2.3.3], 127 link:RelNotes/2.3.2.txt[2.3.2], 128 link:RelNotes/2.3.1.txt[2.3.1], 129 link:RelNotes/2.3.0.txt[2.3]. 130 131* link:v2.2.3/git.html[documentation for release 2.2.3] 132 133* release notes for 134 link:RelNotes/2.2.3.txt[2.2.3], 135 link:RelNotes/2.2.2.txt[2.2.2], 136 link:RelNotes/2.2.1.txt[2.2.1], 137 link:RelNotes/2.2.0.txt[2.2]. 138 139* link:v2.1.4/git.html[documentation for release 2.1.4] 140 141* release notes for 142 link:RelNotes/2.1.4.txt[2.1.4], 143 link:RelNotes/2.1.3.txt[2.1.3], 144 link:RelNotes/2.1.2.txt[2.1.2], 145 link:RelNotes/2.1.1.txt[2.1.1], 146 link:RelNotes/2.1.0.txt[2.1]. 147 148* link:v2.0.5/git.html[documentation for release 2.0.5] 149 150* release notes for 151 link:RelNotes/2.0.5.txt[2.0.5], 152 link:RelNotes/2.0.4.txt[2.0.4], 153 link:RelNotes/2.0.3.txt[2.0.3], 154 link:RelNotes/2.0.2.txt[2.0.2], 155 link:RelNotes/2.0.1.txt[2.0.1], 156 link:RelNotes/2.0.0.txt[2.0.0]. 157 158* link:v1.9.5/git.html[documentation for release 1.9.5] 159 160* release notes for 161 link:RelNotes/1.9.5.txt[1.9.5], 162 link:RelNotes/1.9.4.txt[1.9.4], 163 link:RelNotes/1.9.3.txt[1.9.3], 164 link:RelNotes/1.9.2.txt[1.9.2], 165 link:RelNotes/1.9.1.txt[1.9.1], 166 link:RelNotes/1.9.0.txt[1.9.0]. 167 168* link:v1.8.5.6/git.html[documentation for release 1.8.5.6] 169 170* release notes for 171 link:RelNotes/1.8.5.6.txt[1.8.5.6], 172 link:RelNotes/1.8.5.5.txt[1.8.5.5], 173 link:RelNotes/1.8.5.4.txt[1.8.5.4], 174 link:RelNotes/1.8.5.3.txt[1.8.5.3], 175 link:RelNotes/1.8.5.2.txt[1.8.5.2], 176 link:RelNotes/1.8.5.1.txt[1.8.5.1], 177 link:RelNotes/1.8.5.txt[1.8.5]. 178 179* link:v1.8.4.5/git.html[documentation for release 1.8.4.5] 180 181* release notes for 182 link:RelNotes/1.8.4.5.txt[1.8.4.5], 183 link:RelNotes/1.8.4.4.txt[1.8.4.4], 184 link:RelNotes/1.8.4.3.txt[1.8.4.3], 185 link:RelNotes/1.8.4.2.txt[1.8.4.2], 186 link:RelNotes/1.8.4.1.txt[1.8.4.1], 187 link:RelNotes/1.8.4.txt[1.8.4]. 188 189* link:v1.8.3.4/git.html[documentation for release 1.8.3.4] 190 191* release notes for 192 link:RelNotes/1.8.3.4.txt[1.8.3.4], 193 link:RelNotes/1.8.3.3.txt[1.8.3.3], 194 link:RelNotes/1.8.3.2.txt[1.8.3.2], 195 link:RelNotes/1.8.3.1.txt[1.8.3.1], 196 link:RelNotes/1.8.3.txt[1.8.3]. 197 198* link:v1.8.2.3/git.html[documentation for release 1.8.2.3] 199 200* release notes for 201 link:RelNotes/1.8.2.3.txt[1.8.2.3], 202 link:RelNotes/1.8.2.2.txt[1.8.2.2], 203 link:RelNotes/1.8.2.1.txt[1.8.2.1], 204 link:RelNotes/1.8.2.txt[1.8.2]. 205 206* link:v1.8.1.6/git.html[documentation for release 1.8.1.6] 207 208* release notes for 209 link:RelNotes/1.8.1.6.txt[1.8.1.6], 210 link:RelNotes/1.8.1.5.txt[1.8.1.5], 211 link:RelNotes/1.8.1.4.txt[1.8.1.4], 212 link:RelNotes/1.8.1.3.txt[1.8.1.3], 213 link:RelNotes/1.8.1.2.txt[1.8.1.2], 214 link:RelNotes/1.8.1.1.txt[1.8.1.1], 215 link:RelNotes/1.8.1.txt[1.8.1]. 216 217* link:v1.8.0.3/git.html[documentation for release 1.8.0.3] 218 219* release notes for 220 link:RelNotes/1.8.0.3.txt[1.8.0.3], 221 link:RelNotes/1.8.0.2.txt[1.8.0.2], 222 link:RelNotes/1.8.0.1.txt[1.8.0.1], 223 link:RelNotes/1.8.0.txt[1.8.0]. 224 225* link:v1.7.12.4/git.html[documentation for release 1.7.12.4] 226 227* release notes for 228 link:RelNotes/1.7.12.4.txt[1.7.12.4], 229 link:RelNotes/1.7.12.3.txt[1.7.12.3], 230 link:RelNotes/1.7.12.2.txt[1.7.12.2], 231 link:RelNotes/1.7.12.1.txt[1.7.12.1], 232 link:RelNotes/1.7.12.txt[1.7.12]. 233 234* link:v1.7.11.7/git.html[documentation for release 1.7.11.7] 235 236* release notes for 237 link:RelNotes/1.7.11.7.txt[1.7.11.7], 238 link:RelNotes/1.7.11.6.txt[1.7.11.6], 239 link:RelNotes/1.7.11.5.txt[1.7.11.5], 240 link:RelNotes/1.7.11.4.txt[1.7.11.4], 241 link:RelNotes/1.7.11.3.txt[1.7.11.3], 242 link:RelNotes/1.7.11.2.txt[1.7.11.2], 243 link:RelNotes/1.7.11.1.txt[1.7.11.1], 244 link:RelNotes/1.7.11.txt[1.7.11]. 245 246* link:v1.7.10.5/git.html[documentation for release 1.7.10.5] 247 248* release notes for 249 link:RelNotes/1.7.10.5.txt[1.7.10.5], 250 link:RelNotes/1.7.10.4.txt[1.7.10.4], 251 link:RelNotes/1.7.10.3.txt[1.7.10.3], 252 link:RelNotes/1.7.10.2.txt[1.7.10.2], 253 link:RelNotes/1.7.10.1.txt[1.7.10.1], 254 link:RelNotes/1.7.10.txt[1.7.10]. 255 256* link:v1.7.9.7/git.html[documentation for release 1.7.9.7] 257 258* release notes for 259 link:RelNotes/1.7.9.7.txt[1.7.9.7], 260 link:RelNotes/1.7.9.6.txt[1.7.9.6], 261 link:RelNotes/1.7.9.5.txt[1.7.9.5], 262 link:RelNotes/1.7.9.4.txt[1.7.9.4], 263 link:RelNotes/1.7.9.3.txt[1.7.9.3], 264 link:RelNotes/1.7.9.2.txt[1.7.9.2], 265 link:RelNotes/1.7.9.1.txt[1.7.9.1], 266 link:RelNotes/1.7.9.txt[1.7.9]. 267 268* link:v1.7.8.6/git.html[documentation for release 1.7.8.6] 269 270* release notes for 271 link:RelNotes/1.7.8.6.txt[1.7.8.6], 272 link:RelNotes/1.7.8.5.txt[1.7.8.5], 273 link:RelNotes/1.7.8.4.txt[1.7.8.4], 274 link:RelNotes/1.7.8.3.txt[1.7.8.3], 275 link:RelNotes/1.7.8.2.txt[1.7.8.2], 276 link:RelNotes/1.7.8.1.txt[1.7.8.1], 277 link:RelNotes/1.7.8.txt[1.7.8]. 278 279* link:v1.7.7.7/git.html[documentation for release 1.7.7.7] 280 281* release notes for 282 link:RelNotes/1.7.7.7.txt[1.7.7.7], 283 link:RelNotes/1.7.7.6.txt[1.7.7.6], 284 link:RelNotes/1.7.7.5.txt[1.7.7.5], 285 link:RelNotes/1.7.7.4.txt[1.7.7.4], 286 link:RelNotes/1.7.7.3.txt[1.7.7.3], 287 link:RelNotes/1.7.7.2.txt[1.7.7.2], 288 link:RelNotes/1.7.7.1.txt[1.7.7.1], 289 link:RelNotes/1.7.7.txt[1.7.7]. 290 291* link:v1.7.6.6/git.html[documentation for release 1.7.6.6] 292 293* release notes for 294 link:RelNotes/1.7.6.6.txt[1.7.6.6], 295 link:RelNotes/1.7.6.5.txt[1.7.6.5], 296 link:RelNotes/1.7.6.4.txt[1.7.6.4], 297 link:RelNotes/1.7.6.3.txt[1.7.6.3], 298 link:RelNotes/1.7.6.2.txt[1.7.6.2], 299 link:RelNotes/1.7.6.1.txt[1.7.6.1], 300 link:RelNotes/1.7.6.txt[1.7.6]. 301 302* link:v1.7.5.4/git.html[documentation for release 1.7.5.4] 303 304* release notes for 305 link:RelNotes/1.7.5.4.txt[1.7.5.4], 306 link:RelNotes/1.7.5.3.txt[1.7.5.3], 307 link:RelNotes/1.7.5.2.txt[1.7.5.2], 308 link:RelNotes/1.7.5.1.txt[1.7.5.1], 309 link:RelNotes/1.7.5.txt[1.7.5]. 310 311* link:v1.7.4.5/git.html[documentation for release 1.7.4.5] 312 313* release notes for 314 link:RelNotes/1.7.4.5.txt[1.7.4.5], 315 link:RelNotes/1.7.4.4.txt[1.7.4.4], 316 link:RelNotes/1.7.4.3.txt[1.7.4.3], 317 link:RelNotes/1.7.4.2.txt[1.7.4.2], 318 link:RelNotes/1.7.4.1.txt[1.7.4.1], 319 link:RelNotes/1.7.4.txt[1.7.4]. 320 321* link:v1.7.3.5/git.html[documentation for release 1.7.3.5] 322 323* release notes for 324 link:RelNotes/1.7.3.5.txt[1.7.3.5], 325 link:RelNotes/1.7.3.4.txt[1.7.3.4], 326 link:RelNotes/1.7.3.3.txt[1.7.3.3], 327 link:RelNotes/1.7.3.2.txt[1.7.3.2], 328 link:RelNotes/1.7.3.1.txt[1.7.3.1], 329 link:RelNotes/1.7.3.txt[1.7.3]. 330 331* link:v1.7.2.5/git.html[documentation for release 1.7.2.5] 332 333* release notes for 334 link:RelNotes/1.7.2.5.txt[1.7.2.5], 335 link:RelNotes/1.7.2.4.txt[1.7.2.4], 336 link:RelNotes/1.7.2.3.txt[1.7.2.3], 337 link:RelNotes/1.7.2.2.txt[1.7.2.2], 338 link:RelNotes/1.7.2.1.txt[1.7.2.1], 339 link:RelNotes/1.7.2.txt[1.7.2]. 340 341* link:v1.7.1.4/git.html[documentation for release 1.7.1.4] 342 343* release notes for 344 link:RelNotes/1.7.1.4.txt[1.7.1.4], 345 link:RelNotes/1.7.1.3.txt[1.7.1.3], 346 link:RelNotes/1.7.1.2.txt[1.7.1.2], 347 link:RelNotes/1.7.1.1.txt[1.7.1.1], 348 link:RelNotes/1.7.1.txt[1.7.1]. 349 350* link:v1.7.0.9/git.html[documentation for release 1.7.0.9] 351 352* release notes for 353 link:RelNotes/1.7.0.9.txt[1.7.0.9], 354 link:RelNotes/1.7.0.8.txt[1.7.0.8], 355 link:RelNotes/1.7.0.7.txt[1.7.0.7], 356 link:RelNotes/1.7.0.6.txt[1.7.0.6], 357 link:RelNotes/1.7.0.5.txt[1.7.0.5], 358 link:RelNotes/1.7.0.4.txt[1.7.0.4], 359 link:RelNotes/1.7.0.3.txt[1.7.0.3], 360 link:RelNotes/1.7.0.2.txt[1.7.0.2], 361 link:RelNotes/1.7.0.1.txt[1.7.0.1], 362 link:RelNotes/1.7.0.txt[1.7.0]. 363 364* link:v1.6.6.3/git.html[documentation for release 1.6.6.3] 365 366* release notes for 367 link:RelNotes/1.6.6.3.txt[1.6.6.3], 368 link:RelNotes/1.6.6.2.txt[1.6.6.2], 369 link:RelNotes/1.6.6.1.txt[1.6.6.1], 370 link:RelNotes/1.6.6.txt[1.6.6]. 371 372* link:v1.6.5.9/git.html[documentation for release 1.6.5.9] 373 374* release notes for 375 link:RelNotes/1.6.5.9.txt[1.6.5.9], 376 link:RelNotes/1.6.5.8.txt[1.6.5.8], 377 link:RelNotes/1.6.5.7.txt[1.6.5.7], 378 link:RelNotes/1.6.5.6.txt[1.6.5.6], 379 link:RelNotes/1.6.5.5.txt[1.6.5.5], 380 link:RelNotes/1.6.5.4.txt[1.6.5.4], 381 link:RelNotes/1.6.5.3.txt[1.6.5.3], 382 link:RelNotes/1.6.5.2.txt[1.6.5.2], 383 link:RelNotes/1.6.5.1.txt[1.6.5.1], 384 link:RelNotes/1.6.5.txt[1.6.5]. 385 386* link:v1.6.4.5/git.html[documentation for release 1.6.4.5] 387 388* release notes for 389 link:RelNotes/1.6.4.5.txt[1.6.4.5], 390 link:RelNotes/1.6.4.4.txt[1.6.4.4], 391 link:RelNotes/1.6.4.3.txt[1.6.4.3], 392 link:RelNotes/1.6.4.2.txt[1.6.4.2], 393 link:RelNotes/1.6.4.1.txt[1.6.4.1], 394 link:RelNotes/1.6.4.txt[1.6.4]. 395 396* link:v1.6.3.4/git.html[documentation for release 1.6.3.4] 397 398* release notes for 399 link:RelNotes/1.6.3.4.txt[1.6.3.4], 400 link:RelNotes/1.6.3.3.txt[1.6.3.3], 401 link:RelNotes/1.6.3.2.txt[1.6.3.2], 402 link:RelNotes/1.6.3.1.txt[1.6.3.1], 403 link:RelNotes/1.6.3.txt[1.6.3]. 404 405* release notes for 406 link:RelNotes/1.6.2.5.txt[1.6.2.5], 407 link:RelNotes/1.6.2.4.txt[1.6.2.4], 408 link:RelNotes/1.6.2.3.txt[1.6.2.3], 409 link:RelNotes/1.6.2.2.txt[1.6.2.2], 410 link:RelNotes/1.6.2.1.txt[1.6.2.1], 411 link:RelNotes/1.6.2.txt[1.6.2]. 412 413* link:v1.6.1.3/git.html[documentation for release 1.6.1.3] 414 415* release notes for 416 link:RelNotes/1.6.1.3.txt[1.6.1.3], 417 link:RelNotes/1.6.1.2.txt[1.6.1.2], 418 link:RelNotes/1.6.1.1.txt[1.6.1.1], 419 link:RelNotes/1.6.1.txt[1.6.1]. 420 421* link:v1.6.0.6/git.html[documentation for release 1.6.0.6] 422 423* release notes for 424 link:RelNotes/1.6.0.6.txt[1.6.0.6], 425 link:RelNotes/1.6.0.5.txt[1.6.0.5], 426 link:RelNotes/1.6.0.4.txt[1.6.0.4], 427 link:RelNotes/1.6.0.3.txt[1.6.0.3], 428 link:RelNotes/1.6.0.2.txt[1.6.0.2], 429 link:RelNotes/1.6.0.1.txt[1.6.0.1], 430 link:RelNotes/1.6.0.txt[1.6.0]. 431 432* link:v1.5.6.6/git.html[documentation for release 1.5.6.6] 433 434* release notes for 435 link:RelNotes/1.5.6.6.txt[1.5.6.6], 436 link:RelNotes/1.5.6.5.txt[1.5.6.5], 437 link:RelNotes/1.5.6.4.txt[1.5.6.4], 438 link:RelNotes/1.5.6.3.txt[1.5.6.3], 439 link:RelNotes/1.5.6.2.txt[1.5.6.2], 440 link:RelNotes/1.5.6.1.txt[1.5.6.1], 441 link:RelNotes/1.5.6.txt[1.5.6]. 442 443* link:v1.5.5.6/git.html[documentation for release 1.5.5.6] 444 445* release notes for 446 link:RelNotes/1.5.5.6.txt[1.5.5.6], 447 link:RelNotes/1.5.5.5.txt[1.5.5.5], 448 link:RelNotes/1.5.5.4.txt[1.5.5.4], 449 link:RelNotes/1.5.5.3.txt[1.5.5.3], 450 link:RelNotes/1.5.5.2.txt[1.5.5.2], 451 link:RelNotes/1.5.5.1.txt[1.5.5.1], 452 link:RelNotes/1.5.5.txt[1.5.5]. 453 454* link:v1.5.4.7/git.html[documentation for release 1.5.4.7] 455 456* release notes for 457 link:RelNotes/1.5.4.7.txt[1.5.4.7], 458 link:RelNotes/1.5.4.6.txt[1.5.4.6], 459 link:RelNotes/1.5.4.5.txt[1.5.4.5], 460 link:RelNotes/1.5.4.4.txt[1.5.4.4], 461 link:RelNotes/1.5.4.3.txt[1.5.4.3], 462 link:RelNotes/1.5.4.2.txt[1.5.4.2], 463 link:RelNotes/1.5.4.1.txt[1.5.4.1], 464 link:RelNotes/1.5.4.txt[1.5.4]. 465 466* link:v1.5.3.8/git.html[documentation for release 1.5.3.8] 467 468* release notes for 469 link:RelNotes/1.5.3.8.txt[1.5.3.8], 470 link:RelNotes/1.5.3.7.txt[1.5.3.7], 471 link:RelNotes/1.5.3.6.txt[1.5.3.6], 472 link:RelNotes/1.5.3.5.txt[1.5.3.5], 473 link:RelNotes/1.5.3.4.txt[1.5.3.4], 474 link:RelNotes/1.5.3.3.txt[1.5.3.3], 475 link:RelNotes/1.5.3.2.txt[1.5.3.2], 476 link:RelNotes/1.5.3.1.txt[1.5.3.1], 477 link:RelNotes/1.5.3.txt[1.5.3]. 478 479* link:v1.5.2.5/git.html[documentation for release 1.5.2.5] 480 481* release notes for 482 link:RelNotes/1.5.2.5.txt[1.5.2.5], 483 link:RelNotes/1.5.2.4.txt[1.5.2.4], 484 link:RelNotes/1.5.2.3.txt[1.5.2.3], 485 link:RelNotes/1.5.2.2.txt[1.5.2.2], 486 link:RelNotes/1.5.2.1.txt[1.5.2.1], 487 link:RelNotes/1.5.2.txt[1.5.2]. 488 489* link:v1.5.1.6/git.html[documentation for release 1.5.1.6] 490 491* release notes for 492 link:RelNotes/1.5.1.6.txt[1.5.1.6], 493 link:RelNotes/1.5.1.5.txt[1.5.1.5], 494 link:RelNotes/1.5.1.4.txt[1.5.1.4], 495 link:RelNotes/1.5.1.3.txt[1.5.1.3], 496 link:RelNotes/1.5.1.2.txt[1.5.1.2], 497 link:RelNotes/1.5.1.1.txt[1.5.1.1], 498 link:RelNotes/1.5.1.txt[1.5.1]. 499 500* link:v1.5.0.7/git.html[documentation for release 1.5.0.7] 501 502* release notes for 503 link:RelNotes/1.5.0.7.txt[1.5.0.7], 504 link:RelNotes/1.5.0.6.txt[1.5.0.6], 505 link:RelNotes/1.5.0.5.txt[1.5.0.5], 506 link:RelNotes/1.5.0.3.txt[1.5.0.3], 507 link:RelNotes/1.5.0.2.txt[1.5.0.2], 508 link:RelNotes/1.5.0.1.txt[1.5.0.1], 509 link:RelNotes/1.5.0.txt[1.5.0]. 510 511* documentation for release link:v1.4.4.4/git.html[1.4.4.4], 512 link:v1.3.3/git.html[1.3.3], 513 link:v1.2.6/git.html[1.2.6], 514 link:v1.0.13/git.html[1.0.13]. 515 516============ 517 518endif::stalenotes[] 519 520OPTIONS 521------- 522--version:: 523 Prints the Git suite version that the 'git' program came from. 524 525--help:: 526 Prints the synopsis and a list of the most commonly used 527 commands. If the option `--all` or `-a` is given then all 528 available commands are printed. If a Git command is named this 529 option will bring up the manual page for that command. 530+ 531Other options are available to control how the manual page is 532displayed. See linkgit:git-help[1] for more information, 533because `git --help ...` is converted internally into `git 534help ...`. 535 536-C <path>:: 537 Run as if git was started in '<path>' instead of the current working 538 directory. When multiple `-C` options are given, each subsequent 539 non-absolute `-C <path>` is interpreted relative to the preceding `-C 540 <path>`. 541+ 542This option affects options that expect path name like `--git-dir` and 543`--work-tree` in that their interpretations of the path names would be 544made relative to the working directory caused by the `-C` option. For 545example the following invocations are equivalent: 546 547 git --git-dir=a.git --work-tree=b -C c status 548 git --git-dir=c/a.git --work-tree=c/b status 549 550-c <name>=<value>:: 551 Pass a configuration parameter to the command. The value 552 given will override values from configuration files. 553 The <name> is expected in the same format as listed by 554 'git config' (subkeys separated by dots). 555+ 556Note that omitting the `=` in `git -c foo.bar ...` is allowed and sets 557`foo.bar` to the boolean true value (just like `[foo]bar` would in a 558config file). Including the equals but with an empty value (like `git -c 559foo.bar= ...`) sets `foo.bar` to the empty string. 560 561--exec-path[=<path>]:: 562 Path to wherever your core Git programs are installed. 563 This can also be controlled by setting the GIT_EXEC_PATH 564 environment variable. If no path is given, 'git' will print 565 the current setting and then exit. 566 567--html-path:: 568 Print the path, without trailing slash, where Git's HTML 569 documentation is installed and exit. 570 571--man-path:: 572 Print the manpath (see `man(1)`) for the man pages for 573 this version of Git and exit. 574 575--info-path:: 576 Print the path where the Info files documenting this 577 version of Git are installed and exit. 578 579-p:: 580--paginate:: 581 Pipe all output into 'less' (or if set, $PAGER) if standard 582 output is a terminal. This overrides the `pager.<cmd>` 583 configuration options (see the "Configuration Mechanism" section 584 below). 585 586--no-pager:: 587 Do not pipe Git output into a pager. 588 589--git-dir=<path>:: 590 Set the path to the repository. This can also be controlled by 591 setting the `GIT_DIR` environment variable. It can be an absolute 592 path or relative path to current working directory. 593 594--work-tree=<path>:: 595 Set the path to the working tree. It can be an absolute path 596 or a path relative to the current working directory. 597 This can also be controlled by setting the GIT_WORK_TREE 598 environment variable and the core.worktree configuration 599 variable (see core.worktree in linkgit:git-config[1] for a 600 more detailed discussion). 601 602--namespace=<path>:: 603 Set the Git namespace. See linkgit:gitnamespaces[7] for more 604 details. Equivalent to setting the `GIT_NAMESPACE` environment 605 variable. 606 607--super-prefix=<path>:: 608 Currently for internal use only. Set a prefix which gives a path from 609 above a repository down to its root. One use is to give submodules 610 context about the superproject that invoked it. 611 612--bare:: 613 Treat the repository as a bare repository. If GIT_DIR 614 environment is not set, it is set to the current working 615 directory. 616 617--no-replace-objects:: 618 Do not use replacement refs to replace Git objects. See 619 linkgit:git-replace[1] for more information. 620 621--literal-pathspecs:: 622 Treat pathspecs literally (i.e. no globbing, no pathspec magic). 623 This is equivalent to setting the `GIT_LITERAL_PATHSPECS` environment 624 variable to `1`. 625 626--glob-pathspecs:: 627 Add "glob" magic to all pathspec. This is equivalent to setting 628 the `GIT_GLOB_PATHSPECS` environment variable to `1`. Disabling 629 globbing on individual pathspecs can be done using pathspec 630 magic ":(literal)" 631 632--noglob-pathspecs:: 633 Add "literal" magic to all pathspec. This is equivalent to setting 634 the `GIT_NOGLOB_PATHSPECS` environment variable to `1`. Enabling 635 globbing on individual pathspecs can be done using pathspec 636 magic ":(glob)" 637 638--icase-pathspecs:: 639 Add "icase" magic to all pathspec. This is equivalent to setting 640 the `GIT_ICASE_PATHSPECS` environment variable to `1`. 641 642GIT COMMANDS 643------------ 644 645We divide Git into high level ("porcelain") commands and low level 646("plumbing") commands. 647 648High-level commands (porcelain) 649------------------------------- 650 651We separate the porcelain commands into the main commands and some 652ancillary user utilities. 653 654Main porcelain commands 655~~~~~~~~~~~~~~~~~~~~~~~ 656 657include::cmds-mainporcelain.txt[] 658 659Ancillary Commands 660~~~~~~~~~~~~~~~~~~ 661Manipulators: 662 663include::cmds-ancillarymanipulators.txt[] 664 665Interrogators: 666 667include::cmds-ancillaryinterrogators.txt[] 668 669 670Interacting with Others 671~~~~~~~~~~~~~~~~~~~~~~~ 672 673These commands are to interact with foreign SCM and with other 674people via patch over e-mail. 675 676include::cmds-foreignscminterface.txt[] 677 678 679Low-level commands (plumbing) 680----------------------------- 681 682Although Git includes its 683own porcelain layer, its low-level commands are sufficient to support 684development of alternative porcelains. Developers of such porcelains 685might start by reading about linkgit:git-update-index[1] and 686linkgit:git-read-tree[1]. 687 688The interface (input, output, set of options and the semantics) 689to these low-level commands are meant to be a lot more stable 690than Porcelain level commands, because these commands are 691primarily for scripted use. The interface to Porcelain commands 692on the other hand are subject to change in order to improve the 693end user experience. 694 695The following description divides 696the low-level commands into commands that manipulate objects (in 697the repository, index, and working tree), commands that interrogate and 698compare objects, and commands that move objects and references between 699repositories. 700 701 702Manipulation commands 703~~~~~~~~~~~~~~~~~~~~~ 704 705include::cmds-plumbingmanipulators.txt[] 706 707 708Interrogation commands 709~~~~~~~~~~~~~~~~~~~~~~ 710 711include::cmds-plumbinginterrogators.txt[] 712 713In general, the interrogate commands do not touch the files in 714the working tree. 715 716 717Synching repositories 718~~~~~~~~~~~~~~~~~~~~~ 719 720include::cmds-synchingrepositories.txt[] 721 722The following are helper commands used by the above; end users 723typically do not use them directly. 724 725include::cmds-synchelpers.txt[] 726 727 728Internal helper commands 729~~~~~~~~~~~~~~~~~~~~~~~~ 730 731These are internal helper commands used by other commands; end 732users typically do not use them directly. 733 734include::cmds-purehelpers.txt[] 735 736 737Configuration Mechanism 738----------------------- 739 740Git uses a simple text format to store customizations that are per 741repository and are per user. Such a configuration file may look 742like this: 743 744------------ 745# 746# A '#' or ';' character indicates a comment. 747# 748 749; core variables 750[core] 751 ; Don't trust file modes 752 filemode = false 753 754; user identity 755[user] 756 name = "Junio C Hamano" 757 email = "gitster@pobox.com" 758 759------------ 760 761Various commands read from the configuration file and adjust 762their operation accordingly. See linkgit:git-config[1] for a 763list and more details about the configuration mechanism. 764 765 766Identifier Terminology 767---------------------- 768<object>:: 769 Indicates the object name for any type of object. 770 771<blob>:: 772 Indicates a blob object name. 773 774<tree>:: 775 Indicates a tree object name. 776 777<commit>:: 778 Indicates a commit object name. 779 780<tree-ish>:: 781 Indicates a tree, commit or tag object name. A 782 command that takes a <tree-ish> argument ultimately wants to 783 operate on a <tree> object but automatically dereferences 784 <commit> and <tag> objects that point at a <tree>. 785 786<commit-ish>:: 787 Indicates a commit or tag object name. A 788 command that takes a <commit-ish> argument ultimately wants to 789 operate on a <commit> object but automatically dereferences 790 <tag> objects that point at a <commit>. 791 792<type>:: 793 Indicates that an object type is required. 794 Currently one of: `blob`, `tree`, `commit`, or `tag`. 795 796<file>:: 797 Indicates a filename - almost always relative to the 798 root of the tree structure `GIT_INDEX_FILE` describes. 799 800Symbolic Identifiers 801-------------------- 802Any Git command accepting any <object> can also use the following 803symbolic notation: 804 805HEAD:: 806 indicates the head of the current branch. 807 808<tag>:: 809 a valid tag 'name' 810 (i.e. a `refs/tags/<tag>` reference). 811 812<head>:: 813 a valid head 'name' 814 (i.e. a `refs/heads/<head>` reference). 815 816For a more complete list of ways to spell object names, see 817"SPECIFYING REVISIONS" section in linkgit:gitrevisions[7]. 818 819 820File/Directory Structure 821------------------------ 822 823Please see the linkgit:gitrepository-layout[5] document. 824 825Read linkgit:githooks[5] for more details about each hook. 826 827Higher level SCMs may provide and manage additional information in the 828`$GIT_DIR`. 829 830 831Terminology 832----------- 833Please see linkgit:gitglossary[7]. 834 835 836Environment Variables 837--------------------- 838Various Git commands use the following environment variables: 839 840The Git Repository 841~~~~~~~~~~~~~~~~~~ 842These environment variables apply to 'all' core Git commands. Nb: it 843is worth noting that they may be used/overridden by SCMS sitting above 844Git so take care if using a foreign front-end. 845 846`GIT_INDEX_FILE`:: 847 This environment allows the specification of an alternate 848 index file. If not specified, the default of `$GIT_DIR/index` 849 is used. 850 851`GIT_INDEX_VERSION`:: 852 This environment variable allows the specification of an index 853 version for new repositories. It won't affect existing index 854 files. By default index file version 2 or 3 is used. See 855 linkgit:git-update-index[1] for more information. 856 857`GIT_OBJECT_DIRECTORY`:: 858 If the object storage directory is specified via this 859 environment variable then the sha1 directories are created 860 underneath - otherwise the default `$GIT_DIR/objects` 861 directory is used. 862 863`GIT_ALTERNATE_OBJECT_DIRECTORIES`:: 864 Due to the immutable nature of Git objects, old objects can be 865 archived into shared, read-only directories. This variable 866 specifies a ":" separated (on Windows ";" separated) list 867 of Git object directories which can be used to search for Git 868 objects. New objects will not be written to these directories. 869 870`GIT_DIR`:: 871 If the `GIT_DIR` environment variable is set then it 872 specifies a path to use instead of the default `.git` 873 for the base of the repository. 874 The `--git-dir` command-line option also sets this value. 875 876`GIT_WORK_TREE`:: 877 Set the path to the root of the working tree. 878 This can also be controlled by the `--work-tree` command-line 879 option and the core.worktree configuration variable. 880 881`GIT_NAMESPACE`:: 882 Set the Git namespace; see linkgit:gitnamespaces[7] for details. 883 The `--namespace` command-line option also sets this value. 884 885`GIT_CEILING_DIRECTORIES`:: 886 This should be a colon-separated list of absolute paths. If 887 set, it is a list of directories that Git should not chdir up 888 into while looking for a repository directory (useful for 889 excluding slow-loading network directories). It will not 890 exclude the current working directory or a GIT_DIR set on the 891 command line or in the environment. Normally, Git has to read 892 the entries in this list and resolve any symlink that 893 might be present in order to compare them with the current 894 directory. However, if even this access is slow, you 895 can add an empty entry to the list to tell Git that the 896 subsequent entries are not symlinks and needn't be resolved; 897 e.g., 898 `GIT_CEILING_DIRECTORIES=/maybe/symlink::/very/slow/non/symlink`. 899 900`GIT_DISCOVERY_ACROSS_FILESYSTEM`:: 901 When run in a directory that does not have ".git" repository 902 directory, Git tries to find such a directory in the parent 903 directories to find the top of the working tree, but by default it 904 does not cross filesystem boundaries. This environment variable 905 can be set to true to tell Git not to stop at filesystem 906 boundaries. Like `GIT_CEILING_DIRECTORIES`, this will not affect 907 an explicit repository directory set via `GIT_DIR` or on the 908 command line. 909 910`GIT_COMMON_DIR`:: 911 If this variable is set to a path, non-worktree files that are 912 normally in $GIT_DIR will be taken from this path 913 instead. Worktree-specific files such as HEAD or index are 914 taken from $GIT_DIR. See linkgit:gitrepository-layout[5] and 915 linkgit:git-worktree[1] for 916 details. This variable has lower precedence than other path 917 variables such as GIT_INDEX_FILE, GIT_OBJECT_DIRECTORY... 918 919Git Commits 920~~~~~~~~~~~ 921`GIT_AUTHOR_NAME`:: 922`GIT_AUTHOR_EMAIL`:: 923`GIT_AUTHOR_DATE`:: 924`GIT_COMMITTER_NAME`:: 925`GIT_COMMITTER_EMAIL`:: 926`GIT_COMMITTER_DATE`:: 927'EMAIL':: 928 see linkgit:git-commit-tree[1] 929 930Git Diffs 931~~~~~~~~~ 932`GIT_DIFF_OPTS`:: 933 Only valid setting is "--unified=??" or "-u??" to set the 934 number of context lines shown when a unified diff is created. 935 This takes precedence over any "-U" or "--unified" option 936 value passed on the Git diff command line. 937 938`GIT_EXTERNAL_DIFF`:: 939 When the environment variable `GIT_EXTERNAL_DIFF` is set, the 940 program named by it is called, instead of the diff invocation 941 described above. For a path that is added, removed, or modified, 942 `GIT_EXTERNAL_DIFF` is called with 7 parameters: 943 944 path old-file old-hex old-mode new-file new-hex new-mode 945+ 946where: 947 948 <old|new>-file:: are files GIT_EXTERNAL_DIFF can use to read the 949 contents of <old|new>, 950 <old|new>-hex:: are the 40-hexdigit SHA-1 hashes, 951 <old|new>-mode:: are the octal representation of the file modes. 952+ 953The file parameters can point at the user's working file 954(e.g. `new-file` in "git-diff-files"), `/dev/null` (e.g. `old-file` 955when a new file is added), or a temporary file (e.g. `old-file` in the 956index). `GIT_EXTERNAL_DIFF` should not worry about unlinking the 957temporary file --- it is removed when `GIT_EXTERNAL_DIFF` exits. 958+ 959For a path that is unmerged, `GIT_EXTERNAL_DIFF` is called with 1 960parameter, <path>. 961+ 962For each path `GIT_EXTERNAL_DIFF` is called, two environment variables, 963`GIT_DIFF_PATH_COUNTER` and `GIT_DIFF_PATH_TOTAL` are set. 964 965`GIT_DIFF_PATH_COUNTER`:: 966 A 1-based counter incremented by one for every path. 967 968`GIT_DIFF_PATH_TOTAL`:: 969 The total number of paths. 970 971other 972~~~~~ 973`GIT_MERGE_VERBOSITY`:: 974 A number controlling the amount of output shown by 975 the recursive merge strategy. Overrides merge.verbosity. 976 See linkgit:git-merge[1] 977 978`GIT_PAGER`:: 979 This environment variable overrides `$PAGER`. If it is set 980 to an empty string or to the value "cat", Git will not launch 981 a pager. See also the `core.pager` option in 982 linkgit:git-config[1]. 983 984`GIT_EDITOR`:: 985 This environment variable overrides `$EDITOR` and `$VISUAL`. 986 It is used by several Git commands when, on interactive mode, 987 an editor is to be launched. See also linkgit:git-var[1] 988 and the `core.editor` option in linkgit:git-config[1]. 989 990`GIT_SSH`:: 991`GIT_SSH_COMMAND`:: 992 If either of these environment variables is set then 'git fetch' 993 and 'git push' will use the specified command instead of 'ssh' 994 when they need to connect to a remote system. 995 The command will be given exactly two or four arguments: the 996 'username@host' (or just 'host') from the URL and the shell 997 command to execute on that remote system, optionally preceded by 998 `-p` (literally) and the 'port' from the URL when it specifies 999 something other than the default SSH port.1000+1001`$GIT_SSH_COMMAND` takes precedence over `$GIT_SSH`, and is interpreted1002by the shell, which allows additional arguments to be included.1003`$GIT_SSH` on the other hand must be just the path to a program1004(which can be a wrapper shell script, if additional arguments are1005needed).1006+1007Usually it is easier to configure any desired options through your1008personal `.ssh/config` file. Please consult your ssh documentation1009for further details.10101011`GIT_ASKPASS`::1012 If this environment variable is set, then Git commands which need to1013 acquire passwords or passphrases (e.g. for HTTP or IMAP authentication)1014 will call this program with a suitable prompt as command-line argument1015 and read the password from its STDOUT. See also the `core.askPass`1016 option in linkgit:git-config[1].10171018`GIT_TERMINAL_PROMPT`::1019 If this environment variable is set to `0`, git will not prompt1020 on the terminal (e.g., when asking for HTTP authentication).10211022`GIT_CONFIG_NOSYSTEM`::1023 Whether to skip reading settings from the system-wide1024 `$(prefix)/etc/gitconfig` file. This environment variable can1025 be used along with `$HOME` and `$XDG_CONFIG_HOME` to create a1026 predictable environment for a picky script, or you can set it1027 temporarily to avoid using a buggy `/etc/gitconfig` file while1028 waiting for someone with sufficient permissions to fix it.10291030`GIT_FLUSH`::1031 If this environment variable is set to "1", then commands such1032 as 'git blame' (in incremental mode), 'git rev-list', 'git log',1033 'git check-attr' and 'git check-ignore' will1034 force a flush of the output stream after each record have been1035 flushed. If this1036 variable is set to "0", the output of these commands will be done1037 using completely buffered I/O. If this environment variable is1038 not set, Git will choose buffered or record-oriented flushing1039 based on whether stdout appears to be redirected to a file or not.10401041`GIT_TRACE`::1042 Enables general trace messages, e.g. alias expansion, built-in1043 command execution and external command execution.1044+1045If this variable is set to "1", "2" or "true" (comparison1046is case insensitive), trace messages will be printed to1047stderr.1048+1049If the variable is set to an integer value greater than 21050and lower than 10 (strictly) then Git will interpret this1051value as an open file descriptor and will try to write the1052trace messages into this file descriptor.1053+1054Alternatively, if the variable is set to an absolute path1055(starting with a '/' character), Git will interpret this1056as a file path and will try to write the trace messages1057into it.1058+1059Unsetting the variable, or setting it to empty, "0" or1060"false" (case insensitive) disables trace messages.10611062`GIT_TRACE_PACK_ACCESS`::1063 Enables trace messages for all accesses to any packs. For each1064 access, the pack file name and an offset in the pack is1065 recorded. This may be helpful for troubleshooting some1066 pack-related performance problems.1067 See `GIT_TRACE` for available trace output options.10681069`GIT_TRACE_PACKET`::1070 Enables trace messages for all packets coming in or out of a1071 given program. This can help with debugging object negotiation1072 or other protocol issues. Tracing is turned off at a packet1073 starting with "PACK" (but see `GIT_TRACE_PACKFILE` below).1074 See `GIT_TRACE` for available trace output options.10751076`GIT_TRACE_PACKFILE`::1077 Enables tracing of packfiles sent or received by a1078 given program. Unlike other trace output, this trace is1079 verbatim: no headers, and no quoting of binary data. You almost1080 certainly want to direct into a file (e.g.,1081 `GIT_TRACE_PACKFILE=/tmp/my.pack`) rather than displaying it on1082 the terminal or mixing it with other trace output.1083+1084Note that this is currently only implemented for the client side1085of clones and fetches.10861087`GIT_TRACE_PERFORMANCE`::1088 Enables performance related trace messages, e.g. total execution1089 time of each Git command.1090 See `GIT_TRACE` for available trace output options.10911092`GIT_TRACE_SETUP`::1093 Enables trace messages printing the .git, working tree and current1094 working directory after Git has completed its setup phase.1095 See `GIT_TRACE` for available trace output options.10961097`GIT_TRACE_SHALLOW`::1098 Enables trace messages that can help debugging fetching /1099 cloning of shallow repositories.1100 See `GIT_TRACE` for available trace output options.11011102`GIT_TRACE_CURL`::1103 Enables a curl full trace dump of all incoming and outgoing data,1104 including descriptive information, of the git transport protocol.1105 This is similar to doing curl `--trace-ascii` on the command line.1106 This option overrides setting the `GIT_CURL_VERBOSE` environment1107 variable.1108 See `GIT_TRACE` for available trace output options.11091110`GIT_LITERAL_PATHSPECS`::1111 Setting this variable to `1` will cause Git to treat all1112 pathspecs literally, rather than as glob patterns. For example,1113 running `GIT_LITERAL_PATHSPECS=1 git log -- '*.c'` will search1114 for commits that touch the path `*.c`, not any paths that the1115 glob `*.c` matches. You might want this if you are feeding1116 literal paths to Git (e.g., paths previously given to you by1117 `git ls-tree`, `--raw` diff output, etc).11181119`GIT_GLOB_PATHSPECS`::1120 Setting this variable to `1` will cause Git to treat all1121 pathspecs as glob patterns (aka "glob" magic).11221123`GIT_NOGLOB_PATHSPECS`::1124 Setting this variable to `1` will cause Git to treat all1125 pathspecs as literal (aka "literal" magic).11261127`GIT_ICASE_PATHSPECS`::1128 Setting this variable to `1` will cause Git to treat all1129 pathspecs as case-insensitive.11301131`GIT_REFLOG_ACTION`::1132 When a ref is updated, reflog entries are created to keep1133 track of the reason why the ref was updated (which is1134 typically the name of the high-level command that updated1135 the ref), in addition to the old and new values of the ref.1136 A scripted Porcelain command can use set_reflog_action1137 helper function in `git-sh-setup` to set its name to this1138 variable when it is invoked as the top level command by the1139 end user, to be recorded in the body of the reflog.11401141`GIT_REF_PARANOIA`::1142 If set to `1`, include broken or badly named refs when iterating1143 over lists of refs. In a normal, non-corrupted repository, this1144 does nothing. However, enabling it may help git to detect and1145 abort some operations in the presence of broken refs. Git sets1146 this variable automatically when performing destructive1147 operations like linkgit:git-prune[1]. You should not need to set1148 it yourself unless you want to be paranoid about making sure1149 an operation has touched every ref (e.g., because you are1150 cloning a repository to make a backup).11511152`GIT_ALLOW_PROTOCOL`::1153 If set, provide a colon-separated list of protocols which are1154 allowed to be used with fetch/push/clone. This is useful to1155 restrict recursive submodule initialization from an untrusted1156 repository. Any protocol not mentioned will be disallowed (i.e.,1157 this is a whitelist, not a blacklist). If the variable is not1158 set at all, all protocols are enabled. The protocol names1159 currently used by git are:11601161 - `file`: any local file-based path (including `file://` URLs,1162 or local paths)11631164 - `git`: the anonymous git protocol over a direct TCP1165 connection (or proxy, if configured)11661167 - `ssh`: git over ssh (including `host:path` syntax,1168 `ssh://`, etc).11691170 - `http`: git over http, both "smart http" and "dumb http".1171 Note that this does _not_ include `https`; if you want both,1172 you should specify both as `http:https`.11731174 - any external helpers are named by their protocol (e.g., use1175 `hg` to allow the `git-remote-hg` helper)117611771178Discussion[[Discussion]]1179------------------------11801181More detail on the following is available from the1182link:user-manual.html#git-concepts[Git concepts chapter of the1183user-manual] and linkgit:gitcore-tutorial[7].11841185A Git project normally consists of a working directory with a ".git"1186subdirectory at the top level. The .git directory contains, among other1187things, a compressed object database representing the complete history1188of the project, an "index" file which links that history to the current1189contents of the working tree, and named pointers into that history such1190as tags and branch heads.11911192The object database contains objects of three main types: blobs, which1193hold file data; trees, which point to blobs and other trees to build up1194directory hierarchies; and commits, which each reference a single tree1195and some number of parent commits.11961197The commit, equivalent to what other systems call a "changeset" or1198"version", represents a step in the project's history, and each parent1199represents an immediately preceding step. Commits with more than one1200parent represent merges of independent lines of development.12011202All objects are named by the SHA-1 hash of their contents, normally1203written as a string of 40 hex digits. Such names are globally unique.1204The entire history leading up to a commit can be vouched for by signing1205just that commit. A fourth object type, the tag, is provided for this1206purpose.12071208When first created, objects are stored in individual files, but for1209efficiency may later be compressed together into "pack files".12101211Named pointers called refs mark interesting points in history. A ref1212may contain the SHA-1 name of an object or the name of another ref. Refs1213with names beginning `ref/head/` contain the SHA-1 name of the most1214recent commit (or "head") of a branch under development. SHA-1 names of1215tags of interest are stored under `ref/tags/`. A special ref named1216`HEAD` contains the name of the currently checked-out branch.12171218The index file is initialized with a list of all paths and, for each1219path, a blob object and a set of attributes. The blob object represents1220the contents of the file as of the head of the current branch. The1221attributes (last modified time, size, etc.) are taken from the1222corresponding file in the working tree. Subsequent changes to the1223working tree can be found by comparing these attributes. The index may1224be updated with new content, and new commits may be created from the1225content stored in the index.12261227The index is also capable of storing multiple entries (called "stages")1228for a given pathname. These stages are used to hold the various1229unmerged version of a file when a merge is in progress.12301231FURTHER DOCUMENTATION1232---------------------12331234See the references in the "description" section to get started1235using Git. The following is probably more detail than necessary1236for a first-time user.12371238The link:user-manual.html#git-concepts[Git concepts chapter of the1239user-manual] and linkgit:gitcore-tutorial[7] both provide1240introductions to the underlying Git architecture.12411242See linkgit:gitworkflows[7] for an overview of recommended workflows.12431244See also the link:howto-index.html[howto] documents for some useful1245examples.12461247The internals are documented in the1248link:technical/api-index.html[Git API documentation].12491250Users migrating from CVS may also want to1251read linkgit:gitcvs-migration[7].125212531254Authors1255-------1256Git was started by Linus Torvalds, and is currently maintained by Junio1257C Hamano. Numerous contributions have come from the Git mailing list1258<git@vger.kernel.org>. http://www.openhub.net/p/git/contributors/summary1259gives you a more complete list of contributors.12601261If you have a clone of git.git itself, the1262output of linkgit:git-shortlog[1] and linkgit:git-blame[1] can show you1263the authors for specific parts of the project.12641265Reporting Bugs1266--------------12671268Report bugs to the Git mailing list <git@vger.kernel.org> where the1269development and maintenance is primarily done. You do not have to be1270subscribed to the list to send a message there.12711272SEE ALSO1273--------1274linkgit:gittutorial[7], linkgit:gittutorial-2[7],1275linkgit:giteveryday[7], linkgit:gitcvs-migration[7],1276linkgit:gitglossary[7], linkgit:gitcore-tutorial[7],1277linkgit:gitcli[7], link:user-manual.html[The Git User's Manual],1278linkgit:gitworkflows[7]12791280GIT1281---1282Part of the linkgit:git[1] suite