Git fork
1git-var(1)
2==========
3
4NAME
5----
6git-var - Show a Git logical variable
7
8
9SYNOPSIS
10--------
11[synopsis]
12git var (-l | <variable>)
13
14DESCRIPTION
15-----------
16Prints a Git logical variable. Exits with code 1 if the variable has
17no value.
18
19OPTIONS
20-------
21`-l`::
22 Display the logical variables. In addition, all the
23 variables of the Git configuration file .git/config are listed
24 as well. (However, the configuration variables listing functionality
25 is deprecated in favor of `git config -l`.)
26
27EXAMPLES
28--------
29 $ git var GIT_AUTHOR_IDENT
30 Eric W. Biederman <ebiederm@lnxi.com> 1121223278 -0600
31
32
33VARIABLES
34---------
35`GIT_AUTHOR_IDENT`::
36 The author of a piece of code.
37
38`GIT_COMMITTER_IDENT`::
39 The person who put a piece of code into Git.
40
41`GIT_EDITOR`::
42 Text editor for use by Git commands. The value is meant to be
43 interpreted by the shell when it is used. Examples: `~/bin/vi`,
44 `$SOME_ENVIRONMENT_VARIABLE`, `"C:\Program Files\Vim\gvim.exe"
45 --nofork`. The order of preference is `$GIT_EDITOR`, then
46 `core.editor` configuration value, then `$VISUAL`, then
47 `$EDITOR`, and then the default chosen at compile
48 time, which is usually 'vi'.
49ifdef::git-default-editor[]
50 The build you are using chose '{git-default-editor}' as the default.
51endif::git-default-editor[]
52
53`GIT_SEQUENCE_EDITOR`::
54 Text editor used to edit the 'todo' file while running `git rebase
55 -i`. Like `GIT_EDITOR`, the value is meant to be interpreted by
56 the shell when it is used. The order of preference is
57 `$GIT_SEQUENCE_EDITOR`, then `sequence.editor` configuration value,
58 and then the value of `git var GIT_EDITOR`.
59
60`GIT_PAGER`::
61 Text viewer for use by Git commands (e.g., 'less'). The value
62 is meant to be interpreted by the shell. The order of preference
63 is `$GIT_PAGER`, then the value of `core.pager` configuration, then
64 `$PAGER`, and then the default chosen at compile time (usually `less`).
65ifdef::git-default-pager[]
66 The build you are using chose '{git-default-pager}' as the default.
67endif::git-default-pager[]
68
69`GIT_DEFAULT_BRANCH`::
70 The name of the first branch created in newly initialized repositories.
71
72`GIT_SHELL_PATH`::
73 The path of the binary providing the POSIX shell for commands which use the shell.
74
75`GIT_ATTR_SYSTEM`::
76 The path to the system linkgit:gitattributes[5] file, if one is enabled.
77
78`GIT_ATTR_GLOBAL`::
79 The path to the global (per-user) linkgit:gitattributes[5] file.
80
81`GIT_CONFIG_SYSTEM`::
82 The path to the system configuration file, if one is enabled.
83
84`GIT_CONFIG_GLOBAL`::
85 The path to the global (per-user) configuration files, if any.
86
87Most path values contain only one value. However, some can contain multiple
88values, which are separated by newlines, and are listed in order from highest to
89lowest priority. Callers should be prepared for any such path value to contain
90multiple items.
91
92Note that paths are printed even if they do not exist, but not if they are
93disabled by other environment variables.
94
95SEE ALSO
96--------
97linkgit:git-commit-tree[1]
98linkgit:git-tag[1]
99linkgit:git-config[1]
100
101GIT
102---
103Part of the linkgit:git[1] suite