6 git-help - Display help information about Git
11 'git help' [-a|--all [--[no-]verbose]]
12 [[-i|--info] [-m|--man] [-w|--web]] [<command>|<guide>]
13 'git help' [-g|--guides]
14 'git help' [-c|--config]
19 With no options and no '<command>' or '<guide>' given, the synopsis of the 'git'
20 command and a list of the most commonly used Git commands are printed
21 on the standard output.
23 If the option `--all` or `-a` is given, all available commands are
24 printed on the standard output.
26 If the option `--guides` or `-g` is given, a list of the
27 Git concept guides is also printed on the standard output.
29 If a command, or a guide, is given, a manual page for that command or
30 guide is brought up. The 'man' program is used by default for this
31 purpose, but this can be overridden by other options or configuration
34 If an alias is given, git shows the definition of the alias on
35 standard output. To get the manual page for the aliased command, use
36 `git <command> --help`.
38 Note that `git --help ...` is identical to `git help ...` because the
39 former is internally converted into the latter.
41 To display the linkgit:git[1] man page, use `git help git`.
43 This page can be displayed with 'git help help' or `git help --help`
49 Prints all the available commands on the standard output. This
50 option overrides any given command or guide name.
53 When used with `--all` print description for all recognized
54 commands. This is the default.
58 List all available configuration variables. This is a short
59 summary of the list in linkgit:git-config[1].
63 Prints a list of the Git concept guides on the standard output.
67 Display manual page for the command in the 'info' format. The
68 'info' program will be used for that purpose.
72 Display manual page for the command in the 'man' format. This
73 option may be used to override a value set in the
74 `help.format` configuration variable.
76 By default the 'man' program will be used to display the manual page,
77 but the `man.viewer` configuration variable may be used to choose
78 other display programs (see below).
82 Display manual page for the command in the 'web' (HTML)
83 format. A web browser will be used for that purpose.
85 The web browser can be specified using the configuration variable
86 `help.browser`, or `web.browser` if the former is not set. If none of
87 these config variables is set, the 'git web{litdd}browse' helper script
88 (called by 'git help') will pick a suitable default. See
89 linkgit:git-web{litdd}browse[1] for more information about this.
91 CONFIGURATION VARIABLES
92 -----------------------
97 If no command-line option is passed, the `help.format` configuration
98 variable will be checked. The following values are supported for this
99 variable; they make 'git help' behave as their corresponding command-
102 * "man" corresponds to '-m|--man',
103 * "info" corresponds to '-i|--info',
104 * "web" or "html" correspond to '-w|--web'.
106 help.browser, web.browser and browser.<tool>.path
107 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
109 The `help.browser`, `web.browser` and `browser.<tool>.path` will also
110 be checked if the 'web' format is chosen (either by command-line
111 option or configuration variable). See '-w|--web' in the OPTIONS
112 section above and linkgit:git-web{litdd}browse[1].
117 The `man.viewer` configuration variable will be checked if the 'man'
118 format is chosen. The following values are currently supported:
120 * "man": use the 'man' program as usual,
121 * "woman": use 'emacsclient' to launch the "woman" mode in emacs
122 (this only works starting with emacsclient versions 22),
123 * "konqueror": use 'kfmclient' to open the man page in a new konqueror
124 tab (see 'Note about konqueror' below).
126 Values for other tools can be used if there is a corresponding
127 `man.<tool>.cmd` configuration entry (see below).
129 Multiple values may be given to the `man.viewer` configuration
130 variable. Their corresponding programs will be tried in the order
131 listed in the configuration file.
133 For example, this configuration:
135 ------------------------------------------------
139 ------------------------------------------------
141 will try to use konqueror first. But this may fail (for example, if
142 DISPLAY is not set) and in that case emacs' woman mode will be tried.
144 If everything fails, or if no viewer is configured, the viewer specified
145 in the `GIT_MAN_VIEWER` environment variable will be tried. If that
146 fails too, the 'man' program will be tried anyway.
151 You can explicitly provide a full path to your preferred man viewer by
152 setting the configuration variable `man.<tool>.path`. For example, you
153 can configure the absolute path to konqueror by setting
154 'man.konqueror.path'. Otherwise, 'git help' assumes the tool is
160 When the man viewer, specified by the `man.viewer` configuration
161 variables, is not among the supported ones, then the corresponding
162 `man.<tool>.cmd` configuration variable will be looked up. If this
163 variable exists then the specified tool will be treated as a custom
164 command and a shell eval will be used to run the command with the man
165 page passed as arguments.
170 When 'konqueror' is specified in the `man.viewer` configuration
171 variable, we launch 'kfmclient' to try to open the man page on an
172 already opened konqueror in a new tab if possible.
174 For consistency, we also try such a trick if 'man.konqueror.path' is
175 set to something like `A_PATH_TO/konqueror`. That means we will try to
176 launch `A_PATH_TO/kfmclient` instead.
178 If you really want to use 'konqueror', then you can use something like
181 ------------------------------------------------
186 cmd = A_PATH_TO/konqueror
187 ------------------------------------------------
189 Note about git config --global
190 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
192 Note that all these configuration variables should probably be set
193 using the `--global` flag, for example like this:
195 ------------------------------------------------
196 $ git config --global help.format web
197 $ git config --global web.browser firefox
198 ------------------------------------------------
200 as they are probably more user specific than repository specific.
201 See linkgit:git-config[1] for more information about this.
205 Part of the linkgit:git[1] suite