blob: adcd3e00b201af6182bbc441aa0b288a5d2db8a5 [file] [log] [blame]
Junio C Hamano1a4e8412005-12-27 08:17:231git(7)
2======
3
4NAME
5----
6git - the stupid content tracker
7
8
9SYNOPSIS
10--------
Junio C Hamano6b2cee12006-08-26 08:43:3111[verse]
Junio C Hamanocae86272007-08-21 02:20:4912'git' [--version] [--exec-path[=GIT_EXEC_PATH]]
13 [-p|--paginate|--no-pager]
Junio C Hamanod526ba92007-07-02 00:17:4214 [--bare] [--git-dir=GIT_DIR] [--work-tree=GIT_WORK_TREE]
15 [--help] COMMAND [ARGS]
Junio C Hamano1a4e8412005-12-27 08:17:2316
17DESCRIPTION
18-----------
Junio C Hamanoe27fb932006-04-03 05:34:1019Git is a fast, scalable, distributed revision control system with an
20unusually rich command set that provides both high-level operations
21and full access to internals.
22
23See this link:tutorial.html[tutorial] to get started, then see
24link:everyday.html[Everyday Git] for a useful minimum set of commands, and
25"man git-commandname" for documentation of each command. CVS users may
Junio C Hamano3d30fd52007-05-08 00:32:5326also want to read link:cvs-migration.html[CVS migration]. See
27link:user-manual.html[Git User's Manual] for a more in-depth
28introduction.
Junio C Hamano1a4e8412005-12-27 08:17:2329
Junio C Hamano33db4372006-06-07 19:51:4530The COMMAND is either a name of a Git command (see below) or an alias
Junio C Hamano35738e82008-01-07 07:55:4631as defined in the configuration file (see linkgit:git-config[1]).
Junio C Hamano33db4372006-06-07 19:51:4532
Junio C Hamanob63afff2007-05-01 03:05:5533Formatted and hyperlinked version of the latest git
34documentation can be viewed at
35`http://www.kernel.org/pub/software/scm/git/docs/`.
36
Junio C Hamano9d52e572007-02-13 23:48:2037ifdef::stalenotes[]
38[NOTE]
39============
Junio C Hamano9d52e572007-02-13 23:48:2040
Junio C Hamanoa9b8d242007-05-19 04:51:5541You are reading the documentation for the latest (possibly
42unreleased) version of git, that is available from 'master'
43branch of the `git.git` repository.
44Documentation for older releases are available here:
Junio C Hamano2fc92602007-03-29 01:09:4645
Junio C Hamano0d0679d2008-04-08 06:15:4646* link:v1.5.5/git.html[documentation for release 1.5.5]
47
48* release notes for
Junio C Hamanoe3ddb5b2008-04-21 00:48:0749 link:RelNotes-1.5.5.1.txt[1.5.5.1],
Junio C Hamano0d0679d2008-04-08 06:15:4650 link:RelNotes-1.5.5.txt[1.5.5].
51
Junio C Hamanoe3ddb5b2008-04-21 00:48:0752* link:v1.5.5.1/git.html[documentation for release 1.5.5.1]
53
Junio C Hamano56033be2008-03-28 06:12:5354* link:v1.5.4.5/git.html[documentation for release 1.5.4.5]
Junio C Hamano7b9b4262008-02-02 06:48:3955
56* release notes for
Junio C Hamano56033be2008-03-28 06:12:5357 link:RelNotes-1.5.4.5.txt[1.5.4.5],
Junio C Hamanobb343172008-03-09 10:39:0958 link:RelNotes-1.5.4.4.txt[1.5.4.4],
Junio C Hamanocb174dd2008-02-23 21:03:5459 link:RelNotes-1.5.4.3.txt[1.5.4.3],
Junio C Hamanoe670d0d2008-02-17 20:14:5960 link:RelNotes-1.5.4.2.txt[1.5.4.2],
Junio C Hamanoefe3c632008-02-14 00:51:3161 link:RelNotes-1.5.4.1.txt[1.5.4.1],
Junio C Hamano7b9b4262008-02-02 06:48:3962 link:RelNotes-1.5.4.txt[1.5.4].
63
Junio C Hamano4e272312008-01-08 09:13:2164* link:v1.5.3.8/git.html[documentation for release 1.5.3.8]
Junio C Hamanoa75069c2007-09-04 01:19:2465
66* release notes for
Junio C Hamano4e272312008-01-08 09:13:2167 link:RelNotes-1.5.3.8.txt[1.5.3.8],
Junio C Hamano976c0c42007-12-01 21:57:1468 link:RelNotes-1.5.3.7.txt[1.5.3.7],
Junio C Hamanoe1258662007-11-19 05:03:1969 link:RelNotes-1.5.3.6.txt[1.5.3.6],
Junio C Hamano1c708832007-11-02 02:47:5070 link:RelNotes-1.5.3.5.txt[1.5.3.5],
Junio C Hamanoea719cf2007-10-04 13:06:3571 link:RelNotes-1.5.3.4.txt[1.5.3.4],
Junio C Hamano58992c92007-10-01 16:23:1872 link:RelNotes-1.5.3.3.txt[1.5.3.3],
Junio C Hamano199cdf12007-09-19 18:30:4773 link:RelNotes-1.5.3.2.txt[1.5.3.2],
Junio C Hamano61210dd2007-10-24 11:52:1374 link:RelNotes-1.5.3.1.txt[1.5.3.1],
75 link:RelNotes-1.5.3.txt[1.5.3].
Junio C Hamano75485c82007-05-19 04:20:3376
Junio C Hamanoed7f4f62007-05-20 09:09:0977* release notes for
Junio C Hamano3b178be2007-08-16 04:59:2778 link:RelNotes-1.5.2.5.txt[1.5.2.5],
Junio C Hamano235d53f2007-07-13 00:25:1579 link:RelNotes-1.5.2.4.txt[1.5.2.4],
Junio C Hamano1d90cb02007-07-03 07:05:3180 link:RelNotes-1.5.2.3.txt[1.5.2.3],
Junio C Hamano29b1b922007-06-16 16:30:2681 link:RelNotes-1.5.2.2.txt[1.5.2.2],
82 link:RelNotes-1.5.2.1.txt[1.5.2.1],
Junio C Hamanoed7f4f62007-05-20 09:09:0983 link:RelNotes-1.5.2.txt[1.5.2].
84
85* link:v1.5.1.6/git.html[documentation for release 1.5.1.6]
86
87* release notes for
88 link:RelNotes-1.5.1.6.txt[1.5.1.6],
89 link:RelNotes-1.5.1.5.txt[1.5.1.5],
Junio C Hamanoa9b8d242007-05-19 04:51:5590 link:RelNotes-1.5.1.4.txt[1.5.1.4],
91 link:RelNotes-1.5.1.3.txt[1.5.1.3],
92 link:RelNotes-1.5.1.2.txt[1.5.1.2],
93 link:RelNotes-1.5.1.1.txt[1.5.1.1],
94 link:RelNotes-1.5.1.txt[1.5.1].
Junio C Hamano91d44c52007-05-09 07:16:0795
Junio C Hamanoa9b8d242007-05-19 04:51:5596* link:v1.5.0.7/git.html[documentation for release 1.5.0.7]
Junio C Hamano91d44c52007-05-09 07:16:0797
Junio C Hamanoed7f4f62007-05-20 09:09:0998* release notes for
99 link:RelNotes-1.5.0.7.txt[1.5.0.7],
Junio C Hamanoa9b8d242007-05-19 04:51:55100 link:RelNotes-1.5.0.6.txt[1.5.0.6],
101 link:RelNotes-1.5.0.5.txt[1.5.0.5],
102 link:RelNotes-1.5.0.3.txt[1.5.0.3],
103 link:RelNotes-1.5.0.2.txt[1.5.0.2],
104 link:RelNotes-1.5.0.1.txt[1.5.0.1],
105 link:RelNotes-1.5.0.txt[1.5.0].
Junio C Hamanoe90436a2007-04-22 07:22:13106
Junio C Hamanoa9b8d242007-05-19 04:51:55107* documentation for release link:v1.4.4.4/git.html[1.4.4.4],
108 link:v1.3.3/git.html[1.3.3],
109 link:v1.2.6/git.html[1.2.6],
110 link:v1.0.13/git.html[1.0.13].
Junio C Hamano9d52e572007-02-13 23:48:20111
112============
113
114endif::stalenotes[]
115
Junio C Hamano1a4e8412005-12-27 08:17:23116OPTIONS
117-------
118--version::
Junio C Hamano01078922006-03-10 00:31:47119Prints the git suite version that the 'git' program came from.
Junio C Hamano1a4e8412005-12-27 08:17:23120
121--help::
Junio C Hamano01078922006-03-10 00:31:47122Prints the synopsis and a list of the most commonly used
Junio C Hamano58256872007-12-04 08:31:13123commands. If the option '--all' or '-a' is given then all
124available commands are printed. If a git command is named this
125option will bring up the manual page for that command.
Junio C Hamano0c0da5f2007-12-13 02:45:30126+
127Other options are available to control how the manual page is
Junio C Hamano35738e82008-01-07 07:55:46128displayed. See linkgit:git-help[1] for more information,
Junio C Hamano0c0da5f2007-12-13 02:45:30129because 'git --help ...' is converted internally into 'git
130help ...'.
Junio C Hamano1a4e8412005-12-27 08:17:23131
132--exec-path::
Junio C Hamano01078922006-03-10 00:31:47133Path to wherever your core git programs are installed.
Junio C Hamano1a4e8412005-12-27 08:17:23134This can also be controlled by setting the GIT_EXEC_PATH
135environment variable. If no path is given 'git' will print
136the current setting and then exit.
137
Junio C Hamanof870ef82006-07-29 09:10:13138-p|--paginate::
139Pipe all output into 'less' (or if set, $PAGER).
140
Junio C Hamanocae86272007-08-21 02:20:49141--no-pager::
142Do not pipe git output into a pager.
143
Junio C Hamanof870ef82006-07-29 09:10:13144--git-dir=<path>::
145Set the path to the repository. This can also be controlled by
Junio C Hamano7d575a52008-04-30 08:45:27146setting the GIT_DIR environment variable. It can be an absolute
147path or relative path to current working directory.
Junio C Hamanof870ef82006-07-29 09:10:13148
Junio C Hamanod526ba92007-07-02 00:17:42149--work-tree=<path>::
150Set the path to the working tree. The value will not be
151used in combination with repositories found automatically in
152a .git directory (i.e. $GIT_DIR is not set).
153This can also be controlled by setting the GIT_WORK_TREE
154environment variable and the core.worktree configuration
Junio C Hamano7d575a52008-04-30 08:45:27155variable. It can be an absolute path or relative path to
156the directory specified by --git-dir or GIT_DIR.
157Note: If --git-dir or GIT_DIR are specified but none of
158--work-tree, GIT_WORK_TREE and core.worktree is specified,
159the current working directory is regarded as the top directory
160of your working tree.
Junio C Hamanod526ba92007-07-02 00:17:42161
Junio C Hamanof870ef82006-07-29 09:10:13162--bare::
Junio C Hamanoc435b1c2007-08-28 06:25:35163Treat the repository as a bare repository. If GIT_DIR
164environment is not set, it is set to the current working
165directory.
166
Junio C Hamano1a4e8412005-12-27 08:17:23167
Junio C Hamanoe27fb932006-04-03 05:34:10168FURTHER DOCUMENTATION
169---------------------
Junio C Hamano1a4e8412005-12-27 08:17:23170
Junio C Hamanoe27fb932006-04-03 05:34:10171See the references above to get started using git. The following is
172probably more detail than necessary for a first-time user.
Junio C Hamano1a4e8412005-12-27 08:17:23173
Junio C Hamano597ffcf2007-09-17 17:33:15174The link:user-manual.html#git-concepts[git concepts chapter of the
175user-manual] and the link:core-tutorial.html[Core tutorial] both provide
176introductions to the underlying git architecture.
Junio C Hamano1a4e8412005-12-27 08:17:23177
Junio C Hamanoe27fb932006-04-03 05:34:10178See also the link:howto-index.html[howto] documents for some useful
179examples.
Junio C Hamano1a4e8412005-12-27 08:17:23180
Junio C Hamano3dac5042007-12-15 08:40:54181The internals are documented link:technical/api-index.html[here].
182
Junio C Hamanoe27fb932006-04-03 05:34:10183GIT COMMANDS
184------------
Junio C Hamano1a4e8412005-12-27 08:17:23185
Junio C Hamanoe27fb932006-04-03 05:34:10186We divide git into high level ("porcelain") commands and low level
187("plumbing") commands.
Junio C Hamano1a4e8412005-12-27 08:17:23188
Junio C Hamanob19b4f02006-10-29 20:47:22189High-level commands (porcelain)
190-------------------------------
191
192We separate the porcelain commands into the main commands and some
193ancillary user utilities.
194
195Main porcelain commands
196~~~~~~~~~~~~~~~~~~~~~~~
197
Junio C Hamano7c73c662007-01-19 00:37:50198include::cmds-mainporcelain.txt[]
Junio C Hamanob19b4f02006-10-29 20:47:22199
200Ancillary Commands
201~~~~~~~~~~~~~~~~~~
202Manipulators:
203
Junio C Hamano7c73c662007-01-19 00:37:50204include::cmds-ancillarymanipulators.txt[]
Junio C Hamanob19b4f02006-10-29 20:47:22205
206Interrogators:
207
Junio C Hamano7c73c662007-01-19 00:37:50208include::cmds-ancillaryinterrogators.txt[]
Junio C Hamanob19b4f02006-10-29 20:47:22209
Junio C Hamano4ad294b2007-01-20 02:22:50210
211Interacting with Others
212~~~~~~~~~~~~~~~~~~~~~~~
213
214These commands are to interact with foreign SCM and with other
215people via patch over e-mail.
216
217include::cmds-foreignscminterface.txt[]
218
219
Junio C Hamanoe27fb932006-04-03 05:34:10220Low-level commands (plumbing)
221-----------------------------
Junio C Hamano1a4e8412005-12-27 08:17:23222
Junio C Hamanoe27fb932006-04-03 05:34:10223Although git includes its
224own porcelain layer, its low-level commands are sufficient to support
225development of alternative porcelains. Developers of such porcelains
Junio C Hamano35738e82008-01-07 07:55:46226might start by reading about linkgit:git-update-index[1] and
227linkgit:git-read-tree[1].
Junio C Hamano1a4e8412005-12-27 08:17:23228
Junio C Hamano4ad294b2007-01-20 02:22:50229The interface (input, output, set of options and the semantics)
230to these low-level commands are meant to be a lot more stable
231than Porcelain level commands, because these commands are
232primarily for scripted use. The interface to Porcelain commands
233on the other hand are subject to change in order to improve the
234end user experience.
235
236The following description divides
237the low-level commands into commands that manipulate objects (in
Junio C Hamanoe27fb932006-04-03 05:34:10238the repository, index, and working tree), commands that interrogate and
239compare objects, and commands that move objects and references between
240repositories.
Junio C Hamano1a4e8412005-12-27 08:17:23241
Junio C Hamano4ad294b2007-01-20 02:22:50242
Junio C Hamano1a4e8412005-12-27 08:17:23243Manipulation commands
244~~~~~~~~~~~~~~~~~~~~~
Junio C Hamano1a4e8412005-12-27 08:17:23245
Junio C Hamano7c73c662007-01-19 00:37:50246include::cmds-plumbingmanipulators.txt[]
Junio C Hamano1a4e8412005-12-27 08:17:23247
248
249Interrogation commands
250~~~~~~~~~~~~~~~~~~~~~~
251
Junio C Hamano7c73c662007-01-19 00:37:50252include::cmds-plumbinginterrogators.txt[]
Junio C Hamano1a4e8412005-12-27 08:17:23253
254In general, the interrogate commands do not touch the files in
255the working tree.
256
257
258Synching repositories
259~~~~~~~~~~~~~~~~~~~~~
260
Junio C Hamano7c73c662007-01-19 00:37:50261include::cmds-synchingrepositories.txt[]
Junio C Hamano1a4e8412005-12-27 08:17:23262
Junio C Hamano4ad294b2007-01-20 02:22:50263The following are helper programs used by the above; end users
264typically do not use them directly.
265
266include::cmds-synchelpers.txt[]
267
268
269Internal helper commands
270~~~~~~~~~~~~~~~~~~~~~~~~
271
272These are internal helper commands used by other commands; end
273users typically do not use them directly.
274
275include::cmds-purehelpers.txt[]
276
Junio C Hamano1a4e8412005-12-27 08:17:23277
Junio C Hamano1a4e8412005-12-27 08:17:23278Configuration Mechanism
279-----------------------
280
281Starting from 0.99.9 (actually mid 0.99.8.GIT), `.git/config` file
282is used to hold per-repository configuration options. It is a
Junio C Hamano51c2ab02006-07-09 20:38:54283simple text file modeled after `.ini` format familiar to some
Junio C Hamano1a4e8412005-12-27 08:17:23284people. Here is an example:
285
286------------
287#
288# A '#' or ';' character indicates a comment.
289#
290
291; core variables
292[core]
293; Don't trust file modes
294filemode = false
295
296; user identity
297[user]
298name = "Junio C Hamano"
299email = "junkio@twinsun.com"
300
301------------
302
303Various commands read from the configuration file and adjust
304their operation accordingly.
305
306
307Identifier Terminology
308----------------------
309<object>::
310Indicates the object name for any type of object.
311
312<blob>::
313Indicates a blob object name.
314
315<tree>::
316Indicates a tree object name.
317
318<commit>::
319Indicates a commit object name.
320
321<tree-ish>::
322Indicates a tree, commit or tag object name. A
323command that takes a <tree-ish> argument ultimately wants to
324operate on a <tree> object but automatically dereferences
325<commit> and <tag> objects that point at a <tree>.
326
Junio C Hamano60f8aa82007-03-06 09:58:26327<commit-ish>::
328Indicates a commit or tag object name. A
329command that takes a <commit-ish> argument ultimately wants to
330operate on a <commit> object but automatically dereferences
331<tag> objects that point at a <commit>.
332
Junio C Hamano1a4e8412005-12-27 08:17:23333<type>::
334Indicates that an object type is required.
335Currently one of: `blob`, `tree`, `commit`, or `tag`.
336
337<file>::
338Indicates a filename - almost always relative to the
339root of the tree structure `GIT_INDEX_FILE` describes.
340
341Symbolic Identifiers
342--------------------
343Any git command accepting any <object> can also use the following
344symbolic notation:
345
346HEAD::
347indicates the head of the current branch (i.e. the
348contents of `$GIT_DIR/HEAD`).
349
350<tag>::
351a valid tag 'name'
352(i.e. the contents of `$GIT_DIR/refs/tags/<tag>`).
353
354<head>::
355a valid head 'name'
356(i.e. the contents of `$GIT_DIR/refs/heads/<head>`).
357
Junio C Hamanoff4b4312006-10-25 22:55:31358For a more complete list of ways to spell object names, see
Junio C Hamano35738e82008-01-07 07:55:46359"SPECIFYING REVISIONS" section in linkgit:git-rev-parse[1].
Junio C Hamanoff4b4312006-10-25 22:55:31360
Junio C Hamano1a4e8412005-12-27 08:17:23361
362File/Directory Structure
363------------------------
364
Junio C Hamano764a6672007-10-23 01:23:31365Please see the link:repository-layout.html[repository layout] document.
Junio C Hamano1a4e8412005-12-27 08:17:23366
Junio C Hamano2fbcd212008-05-14 22:26:07367Read linkgit:githooks[5][hooks] for more details about each hook.
Junio C Hamano818f7d62006-03-26 01:49:30368
Junio C Hamano1a4e8412005-12-27 08:17:23369Higher level SCMs may provide and manage additional information in the
370`$GIT_DIR`.
371
372
373Terminology
374-----------
Junio C Hamano764a6672007-10-23 01:23:31375Please see the link:glossary.html[glossary] document.
Junio C Hamano1a4e8412005-12-27 08:17:23376
377
378Environment Variables
379---------------------
380Various git commands use the following environment variables:
381
382The git Repository
383~~~~~~~~~~~~~~~~~~
384These environment variables apply to 'all' core git commands. Nb: it
385is worth noting that they may be used/overridden by SCMS sitting above
386git so take care if using Cogito etc.
387
388'GIT_INDEX_FILE'::
389This environment allows the specification of an alternate
390index file. If not specified, the default of `$GIT_DIR/index`
391is used.
392
393'GIT_OBJECT_DIRECTORY'::
394If the object storage directory is specified via this
395environment variable then the sha1 directories are created
396underneath - otherwise the default `$GIT_DIR/objects`
397directory is used.
398
399'GIT_ALTERNATE_OBJECT_DIRECTORIES'::
400Due to the immutable nature of git objects, old objects can be
401archived into shared, read-only directories. This variable
402specifies a ":" separated list of git object directories which
403can be used to search for git objects. New objects will not be
404written to these directories.
405
406'GIT_DIR'::
407If the 'GIT_DIR' environment variable is set then it
408specifies a path to use instead of the default `.git`
409for the base of the repository.
410
Junio C Hamanod526ba92007-07-02 00:17:42411'GIT_WORK_TREE'::
412Set the path to the working tree. The value will not be
413used in combination with repositories found automatically in
414a .git directory (i.e. $GIT_DIR is not set).
415This can also be controlled by the '--work-tree' command line
416option and the core.worktree configuration variable.
417
Junio C Hamano1a4e8412005-12-27 08:17:23418git Commits
419~~~~~~~~~~~
420'GIT_AUTHOR_NAME'::
421'GIT_AUTHOR_EMAIL'::
422'GIT_AUTHOR_DATE'::
423'GIT_COMMITTER_NAME'::
424'GIT_COMMITTER_EMAIL'::
Junio C Hamano469d60e2007-04-29 18:30:34425'GIT_COMMITTER_DATE'::
426'EMAIL'::
Junio C Hamano35738e82008-01-07 07:55:46427see linkgit:git-commit-tree[1]
Junio C Hamano1a4e8412005-12-27 08:17:23428
429git Diffs
430~~~~~~~~~
431'GIT_DIFF_OPTS'::
Junio C Hamano1c437122006-11-28 02:22:25432Only valid setting is "--unified=??" or "-u??" to set the
433number of context lines shown when a unified diff is created.
434This takes precedence over any "-U" or "--unified" option
435value passed on the git diff command line.
436
Junio C Hamano1a4e8412005-12-27 08:17:23437'GIT_EXTERNAL_DIFF'::
Junio C Hamano1c437122006-11-28 02:22:25438When the environment variable 'GIT_EXTERNAL_DIFF' is set, the
439program named by it is called, instead of the diff invocation
440described above. For a path that is added, removed, or modified,
441 'GIT_EXTERNAL_DIFF' is called with 7 parameters:
442
443path old-file old-hex old-mode new-file new-hex new-mode
444+
445where:
446
447<old|new>-file:: are files GIT_EXTERNAL_DIFF can use to read the
448 contents of <old|new>,
449<old|new>-hex:: are the 40-hexdigit SHA1 hashes,
450<old|new>-mode:: are the octal representation of the file modes.
451
452+
453The file parameters can point at the user's working file
454(e.g. `new-file` in "git-diff-files"), `/dev/null` (e.g. `old-file`
455when a new file is added), or a temporary file (e.g. `old-file` in the
456index). 'GIT_EXTERNAL_DIFF' should not worry about unlinking the
457temporary file --- it is removed when 'GIT_EXTERNAL_DIFF' exits.
458+
459For a path that is unmerged, 'GIT_EXTERNAL_DIFF' is called with 1
460parameter, <path>.
Junio C Hamano1a4e8412005-12-27 08:17:23461
Junio C Hamano7ccb9fd2006-07-15 01:38:40462other
463~~~~~
Junio C Hamano1e6e0062007-07-13 05:33:25464'GIT_MERGE_VERBOSITY'::
465A number controlling the amount of output shown by
466the recursive merge strategy. Overrides merge.verbosity.
Junio C Hamano35738e82008-01-07 07:55:46467See linkgit:git-merge[1]
Junio C Hamano1e6e0062007-07-13 05:33:25468
Junio C Hamano85e45fa2006-08-13 07:47:41469'GIT_PAGER'::
Junio C Hamanof6002a92007-07-20 10:28:22470This environment variable overrides `$PAGER`. If it is set
471to an empty string or to the value "cat", git will not launch
472a pager.
Junio C Hamano85e45fa2006-08-13 07:47:41473
Junio C Hamano4cd1c0e2007-08-06 04:39:14474'GIT_SSH'::
Junio C Hamano35738e82008-01-07 07:55:46475If this environment variable is set then linkgit:git-fetch[1]
476and linkgit:git-push[1] will use this command instead
Junio C Hamano4cd1c0e2007-08-06 04:39:14477of `ssh` when they need to connect to a remote system.
478The 'GIT_SSH' command will be given exactly two arguments:
479the 'username@host' (or just 'host') from the URL and the
480shell command to execute on that remote system.
481+
482To pass options to the program that you want to list in GIT_SSH
483you will need to wrap the program and options into a shell script,
484then set GIT_SSH to refer to the shell script.
485+
486Usually it is easier to configure any desired options through your
487personal `.ssh/config` file. Please consult your ssh documentation
488for further details.
489
Junio C Hamano401939f2007-07-01 06:34:30490'GIT_FLUSH'::
491If this environment variable is set to "1", then commands such
492as git-blame (in incremental mode), git-rev-list, git-log,
493git-whatchanged, etc., will force a flush of the output stream
494after each commit-oriented record have been flushed. If this
495variable is set to "0", the output of these commands will be done
496using completely buffered I/O. If this environment variable is
497not set, git will choose buffered or record-oriented flushing
498based on whether stdout appears to be redirected to a file or not.
499
Junio C Hamano7ccb9fd2006-07-15 01:38:40500'GIT_TRACE'::
Junio C Hamanoef4b48b2006-09-04 10:08:34501If this variable is set to "1", "2" or "true" (comparison
502is case insensitive), git will print `trace:` messages on
Junio C Hamano7ccb9fd2006-07-15 01:38:40503stderr telling about alias expansion, built-in command
504execution and external command execution.
Junio C Hamanoef4b48b2006-09-04 10:08:34505If this variable is set to an integer value greater than 1
506and lower than 10 (strictly) then git will interpret this
507value as an open file descriptor and will try to write the
508trace messages into this file descriptor.
509Alternatively, if this variable is set to an absolute path
510(starting with a '/' character), git will interpret this
511as a file path and will try to write the trace messages
512into it.
Junio C Hamano7ccb9fd2006-07-15 01:38:40513
Junio C Hamano1a4e8412005-12-27 08:17:23514Discussion[[Discussion]]
515------------------------
Junio C Hamano597ffcf2007-09-17 17:33:15516
517More detail on the following is available from the
518link:user-manual.html#git-concepts[git concepts chapter of the
519user-manual] and the link:core-tutorial.html[Core tutorial].
520
521A git project normally consists of a working directory with a ".git"
522subdirectory at the top level. The .git directory contains, among other
523things, a compressed object database representing the complete history
524of the project, an "index" file which links that history to the current
525contents of the working tree, and named pointers into that history such
526as tags and branch heads.
527
528The object database contains objects of three main types: blobs, which
529hold file data; trees, which point to blobs and other trees to build up
Junio C Hamanofe986052007-12-19 07:33:38530directory hierarchies; and commits, which each reference a single tree
Junio C Hamano597ffcf2007-09-17 17:33:15531and some number of parent commits.
532
533The commit, equivalent to what other systems call a "changeset" or
534"version", represents a step in the project's history, and each parent
535represents an immediately preceding step. Commits with more than one
536parent represent merges of independent lines of development.
537
538All objects are named by the SHA1 hash of their contents, normally
539written as a string of 40 hex digits. Such names are globally unique.
540The entire history leading up to a commit can be vouched for by signing
541just that commit. A fourth object type, the tag, is provided for this
542purpose.
543
544When first created, objects are stored in individual files, but for
545efficiency may later be compressed together into "pack files".
546
547Named pointers called refs mark interesting points in history. A ref
548may contain the SHA1 name of an object or the name of another ref. Refs
549with names beginning `ref/head/` contain the SHA1 name of the most
Junio C Hamanofe986052007-12-19 07:33:38550recent commit (or "head") of a branch under development. SHA1 names of
Junio C Hamano597ffcf2007-09-17 17:33:15551tags of interest are stored under `ref/tags/`. A special ref named
552`HEAD` contains the name of the currently checked-out branch.
553
554The index file is initialized with a list of all paths and, for each
555path, a blob object and a set of attributes. The blob object represents
556the contents of the file as of the head of the current branch. The
557attributes (last modified time, size, etc.) are taken from the
558corresponding file in the working tree. Subsequent changes to the
559working tree can be found by comparing these attributes. The index may
560be updated with new content, and new commits may be created from the
561content stored in the index.
562
563The index is also capable of storing multiple entries (called "stages")
564for a given pathname. These stages are used to hold the various
565unmerged version of a file when a merge is in progress.
Junio C Hamano1a4e8412005-12-27 08:17:23566
567Authors
568-------
569* git's founding father is Linus Torvalds <torvalds@osdl.org>.
Junio C Hamanodbb64592007-09-01 11:17:39570* The current git nurse is Junio C Hamano <gitster@pobox.com>.
Junio C Hamanoe0facb92007-12-05 10:59:48571* The git potty was written by Andreas Ericsson <ae@op5.se>.
Junio C Hamano1a4e8412005-12-27 08:17:23572* General upbringing is handled by the git-list <git@vger.kernel.org>.
573
574Documentation
575--------------
576The documentation for git suite was started by David Greaves
577<david@dgreaves.com>, and later enhanced greatly by the
578contributors on the git-list <git@vger.kernel.org>.
579
580GIT
581---
Junio C Hamano35738e82008-01-07 07:55:46582Part of the linkgit:git[7] suite