]> git.ipfire.org Git - thirdparty/git.git/blame - Documentation/git-web--browse.txt
Sync with maint
[thirdparty/git.git] / Documentation / git-web--browse.txt
CommitLineData
28394787
JH
1git-web{litdd}browse(1)
2=======================
cb45f83c
CC
3
4NAME
5----
2de9b711 6git-web--browse - Git helper script to launch a web browser
cb45f83c
CC
7
8SYNOPSIS
9--------
7791a1d9 10[verse]
de613050 11'git web{litdd}browse' [<options>] <url|file>...
cb45f83c
CC
12
13DESCRIPTION
14-----------
15
16This script tries, as much as possible, to display the URLs and FILEs
17that are passed as arguments, as HTML pages in new tabs on an already
18opened web browser.
19
20The following browsers (or commands) are currently supported:
21
22* firefox (this is the default under X Window when not using KDE)
23* iceweasel
81f42f11
GB
24* seamonkey
25* iceape
14ea67c0
GB
26* chromium (also supported as chromium-browser)
27* google-chrome (also supported as chrome)
ac3a4a26 28* konqueror (this is the default under KDE, see 'Note about konqueror' below)
81f42f11 29* opera
cb45f83c 30* w3m (this is the default outside graphical environments)
81f42f11 31* elinks
cb45f83c
CC
32* links
33* lynx
34* dillo
35* open (this is the default under Mac OS X GUI)
3b9b1163 36* start (this is the default under MinGW)
cc2f6b68 37* cygstart (this is the default under Cygwin)
6ca0f80b 38* xdg-open
cb45f83c 39
1658c614
CC
40Custom commands may also be specified.
41
cb45f83c
CC
42OPTIONS
43-------
62b4698e
ŠN
44-b <browser>::
45--browser=<browser>::
46 Use the specified browser. It must be in the list of supported
cb45f83c
CC
47 browsers.
48
62b4698e
ŠN
49-t <browser>::
50--tool=<browser>::
cb45f83c
CC
51 Same as above.
52
62b4698e
ŠN
53-c <conf.var>::
54--config=<conf.var>::
2de9b711 55 CONF.VAR is looked up in the Git config files. If it's set,
62b4698e 56 then its value specifies the browser that should be used.
cb45f83c
CC
57
58CONFIGURATION VARIABLES
59-----------------------
60
1658c614
CC
61CONF.VAR (from -c option) and web.browser
62~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
63
cb45f83c 64The web browser can be specified using a configuration variable passed
ae9f6311 65with the -c (or --config) command-line option, or the `web.browser`
cb45f83c
CC
66configuration variable if the former is not used.
67
1658c614
CC
68browser.<tool>.path
69~~~~~~~~~~~~~~~~~~~
70
cb45f83c 71You can explicitly provide a full path to your preferred browser by
ae9f6311 72setting the configuration variable `browser.<tool>.path`. For example,
cb45f83c 73you can configure the absolute path to firefox by setting
565e135a 74'browser.firefox.path'. Otherwise, 'git web{litdd}browse' assumes the tool
cb45f83c
CC
75is available in PATH.
76
1658c614
CC
77browser.<tool>.cmd
78~~~~~~~~~~~~~~~~~~
79
80When the browser, specified by options or configuration variables, is
81not among the supported ones, then the corresponding
ae9f6311 82`browser.<tool>.cmd` configuration variable will be looked up. If this
28394787 83variable exists then 'git web{litdd}browse' will treat the specified tool
1658c614
CC
84as a custom command and will use a shell eval to run the command with
85the URLs passed as arguments.
86
76a8788c 87NOTE ABOUT KONQUEROR
ac3a4a26
CC
88--------------------
89
06ab60c0 90When 'konqueror' is specified by a command-line option or a
ac3a4a26
CC
91configuration variable, we launch 'kfmclient' to try to open the HTML
92man page on an already opened konqueror in a new tab if possible.
93
ed020917 94For consistency, we also try such a trick if 'browser.konqueror.path' is
68ed71b5
CB
95set to something like `A_PATH_TO/konqueror`. That means we will try to
96launch `A_PATH_TO/kfmclient` instead.
ac3a4a26
CC
97
98If you really want to use 'konqueror', then you can use something like
99the following:
100
101------------------------------------------------
102 [web]
103 browser = konq
104
105 [browser "konq"]
106 cmd = A_PATH_TO/konqueror
107------------------------------------------------
108
b1889c36 109Note about git-config --global
1658c614
CC
110~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
111
cb45f83c 112Note that these configuration variables should probably be set using
bcf9626a 113the `--global` flag, for example like this:
cb45f83c
CC
114
115------------------------------------------------
116$ git config --global web.browser firefox
117------------------------------------------------
118
119as they are probably more user specific than repository specific.
120See linkgit:git-config[1] for more information about this.
121
cb45f83c
CC
122GIT
123---
9e1f0a85 124Part of the linkgit:git[1] suite