Eric W. Biederman | aed022a | 2005-07-14 18:55:09 -0600 | [diff] [blame] | 1 | git-var(1) |
Linus Torvalds | 71931c1 | 2005-07-15 14:57:09 -0700 | [diff] [blame] | 2 | ========== |
Eric W. Biederman | aed022a | 2005-07-14 18:55:09 -0600 | [diff] [blame] | 3 | |
| 4 | NAME |
| 5 | ---- |
Thomas Ackermann | 2de9b71 | 2013-01-21 20:17:53 +0100 | [diff] [blame] | 6 | git-var - Show a Git logical variable |
Eric W. Biederman | aed022a | 2005-07-14 18:55:09 -0600 | [diff] [blame] | 7 | |
| 8 | |
| 9 | SYNOPSIS |
| 10 | -------- |
Martin von Zweigbergk | 7791a1d | 2011-07-01 22:38:26 -0400 | [diff] [blame] | 11 | [verse] |
Ævar Arnfjörð Bjarmason | e2f4e7e | 2022-10-13 17:39:06 +0200 | [diff] [blame] | 12 | 'git var' (-l | <variable>) |
Eric W. Biederman | aed022a | 2005-07-14 18:55:09 -0600 | [diff] [blame] | 13 | |
| 14 | DESCRIPTION |
| 15 | ----------- |
Sean Allred | 26b8abc | 2022-11-26 14:17:56 +0000 | [diff] [blame] | 16 | Prints a Git logical variable. Exits with code 1 if the variable has |
| 17 | no value. |
Eric W. Biederman | aed022a | 2005-07-14 18:55:09 -0600 | [diff] [blame] | 18 | |
Jonas Fonseca | df8baa4 | 2005-10-03 19:16:30 +0200 | [diff] [blame] | 19 | OPTIONS |
| 20 | ------- |
| 21 | -l:: |
Petr Baudis | 4ee6bc9 | 2006-04-25 00:59:28 +0200 | [diff] [blame] | 22 | Cause the logical variables to be listed. In addition, all the |
Thomas Ackermann | 2de9b71 | 2013-01-21 20:17:53 +0100 | [diff] [blame] | 23 | variables of the Git configuration file .git/config are listed |
Petr Baudis | e1cbc46 | 2006-04-25 00:59:30 +0200 | [diff] [blame] | 24 | as well. (However, the configuration variables listing functionality |
Thomas Rast | ca76828 | 2010-01-07 17:49:12 +0100 | [diff] [blame] | 25 | is deprecated in favor of `git config -l`.) |
Eric W. Biederman | aed022a | 2005-07-14 18:55:09 -0600 | [diff] [blame] | 26 | |
Nguyễn Thái Ngọc Duy | 76a8788 | 2018-04-30 17:35:33 +0200 | [diff] [blame] | 27 | EXAMPLES |
Eric W. Biederman | aed022a | 2005-07-14 18:55:09 -0600 | [diff] [blame] | 28 | -------- |
Jonathan Nieder | b1889c3 | 2008-06-30 01:09:04 -0500 | [diff] [blame] | 29 | $ git var GIT_AUTHOR_IDENT |
Jonas Fonseca | df8baa4 | 2005-10-03 19:16:30 +0200 | [diff] [blame] | 30 | Eric W. Biederman <ebiederm@lnxi.com> 1121223278 -0600 |
Eric W. Biederman | aed022a | 2005-07-14 18:55:09 -0600 | [diff] [blame] | 31 | |
| 32 | |
| 33 | VARIABLES |
Nguyễn Thái Ngọc Duy | 76a8788 | 2018-04-30 17:35:33 +0200 | [diff] [blame] | 34 | --------- |
Jonas Fonseca | df8baa4 | 2005-10-03 19:16:30 +0200 | [diff] [blame] | 35 | GIT_AUTHOR_IDENT:: |
Eric W. Biederman | aed022a | 2005-07-14 18:55:09 -0600 | [diff] [blame] | 36 | The author of a piece of code. |
| 37 | |
Jonas Fonseca | df8baa4 | 2005-10-03 19:16:30 +0200 | [diff] [blame] | 38 | GIT_COMMITTER_IDENT:: |
Thomas Ackermann | 2de9b71 | 2013-01-21 20:17:53 +0100 | [diff] [blame] | 39 | The person who put a piece of code into Git. |
Eric W. Biederman | aed022a | 2005-07-14 18:55:09 -0600 | [diff] [blame] | 40 | |
Jonathan Nieder | 44fcb49 | 2009-11-11 18:01:27 -0600 | [diff] [blame] | 41 | GIT_EDITOR:: |
Thomas Ackermann | 2de9b71 | 2013-01-21 20:17:53 +0100 | [diff] [blame] | 42 | Text editor for use by Git commands. The value is meant to be |
Jonathan Nieder | 44fcb49 | 2009-11-11 18:01:27 -0600 | [diff] [blame] | 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 the `$GIT_EDITOR` |
| 46 | environment variable, then `core.editor` configuration, then |
Jonathan Nieder | 4e0ce4d | 2012-03-31 03:42:34 -0500 | [diff] [blame] | 47 | `$VISUAL`, then `$EDITOR`, and then the default chosen at compile |
| 48 | time, which is usually 'vi'. |
Jonathan Nieder | 5b58619 | 2012-03-31 03:44:53 -0500 | [diff] [blame] | 49 | ifdef::git-default-editor[] |
| 50 | The build you are using chose '{git-default-editor}' as the default. |
| 51 | endif::git-default-editor[] |
Jonathan Nieder | 44fcb49 | 2009-11-11 18:01:27 -0600 | [diff] [blame] | 52 | |
Sean Allred | 4c3dd93 | 2022-12-17 23:09:59 +0000 | [diff] [blame] | 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 the |
| 57 | `$GIT_SEQUENCE_EDITOR` environment variable, then |
| 58 | `sequence.editor` configuration, and then the value of `git var |
| 59 | GIT_EDITOR`. |
| 60 | |
Jonathan Nieder | 6361824 | 2009-10-30 20:41:27 -0500 | [diff] [blame] | 61 | GIT_PAGER:: |
Thomas Ackermann | 2de9b71 | 2013-01-21 20:17:53 +0100 | [diff] [blame] | 62 | Text viewer for use by Git commands (e.g., 'less'). The value |
Jonathan Nieder | 6361824 | 2009-10-30 20:41:27 -0500 | [diff] [blame] | 63 | is meant to be interpreted by the shell. The order of preference |
| 64 | is the `$GIT_PAGER` environment variable, then `core.pager` |
Jonathan Nieder | 4e0ce4d | 2012-03-31 03:42:34 -0500 | [diff] [blame] | 65 | configuration, then `$PAGER`, and then the default chosen at |
| 66 | compile time (usually 'less'). |
Jonathan Nieder | 5b58619 | 2012-03-31 03:44:53 -0500 | [diff] [blame] | 67 | ifdef::git-default-pager[] |
| 68 | The build you are using chose '{git-default-pager}' as the default. |
| 69 | endif::git-default-pager[] |
Jonathan Nieder | 6361824 | 2009-10-30 20:41:27 -0500 | [diff] [blame] | 70 | |
Thomas Weißschuh | e06c9e1 | 2021-11-03 21:17:02 +0100 | [diff] [blame] | 71 | GIT_DEFAULT_BRANCH:: |
| 72 | The name of the first branch created in newly initialized repositories. |
| 73 | |
Junio C Hamano | 56ae8df | 2008-05-28 16:55:27 -0700 | [diff] [blame] | 74 | SEE ALSO |
Eric W. Biederman | aed022a | 2005-07-14 18:55:09 -0600 | [diff] [blame] | 75 | -------- |
Dan McGee | 5162e69 | 2007-12-29 00:20:38 -0600 | [diff] [blame] | 76 | linkgit:git-commit-tree[1] |
| 77 | linkgit:git-tag[1] |
| 78 | linkgit:git-config[1] |
Eric W. Biederman | aed022a | 2005-07-14 18:55:09 -0600 | [diff] [blame] | 79 | |
Eric W. Biederman | aed022a | 2005-07-14 18:55:09 -0600 | [diff] [blame] | 80 | GIT |
| 81 | --- |
Christian Couder | 9e1f0a8 | 2008-06-06 09:07:32 +0200 | [diff] [blame] | 82 | Part of the linkgit:git[1] suite |