1 <?xml version="1.0" encoding="UTF-8"?>
\r
2 <!DOCTYPE sect2 SYSTEM "../../../dtd/dblite.dtd">
\r
4 <sect2 lang="en" id="git-ls-remote(1)">
\r
5 <title>git-ls-remote(1)</title>
\r
7 <primary>git-ls-remote(1)</primary>
\r
9 <simplesect id="git-ls-remote(1)__name">
\r
11 <simpara>git-ls-remote - List references in a remote repository</simpara>
\r
13 <simplesect id="git-ls-remote(1)__synopsis">
\r
14 <title>SYNOPSIS</title>
\r
16 <literallayout><emphasis>git ls-remote</emphasis> [--heads] [--tags] [--refs] [--upload-pack=<exec>]
\r
17 [-q | --quiet] [--exit-code] [--get-url] [--sort=<key>]
\r
18 [--symref] [<repository> [<refs>…]]</literallayout>
\r
21 <simplesect id="git-ls-remote(1)__description">
\r
22 <title>DESCRIPTION</title>
\r
23 <simpara>Displays references available in a remote repository along with the associated
\r
24 commit IDs.</simpara>
\r
26 <simplesect id="git-ls-remote(1)__options">
\r
27 <title>OPTIONS</title>
\r
44 Limit to only refs/heads and refs/tags, respectively.
\r
45 These options are <emphasis>not</emphasis> mutually exclusive; when given
\r
46 both, references stored in refs/heads and refs/tags are
\r
47 displayed. Note that <emphasis>git ls-remote -h</emphasis> used without
\r
48 anything else on the command line gives help, consistent
\r
49 with other git subcommands.
\r
59 Do not show peeled tags or pseudorefs like <emphasis>HEAD</emphasis> in the output.
\r
72 Do not print remote URL to stderr.
\r
78 --upload-pack=<exec>
\r
82 Specify the full path of <emphasis>git-upload-pack</emphasis> on the remote
\r
83 host. This allows listing references from repositories accessed via
\r
84 SSH and where the SSH daemon does not use the PATH configured by the
\r
95 Exit with status "2" when no matching refs are found in the remote
\r
96 repository. Usually the command exits with status "0" to indicate
\r
97 it successfully talked with the remote repository, whether it
\r
98 found any matching refs.
\r
108 Expand the URL of the given remote repository taking into account any
\r
109 "url.<base>.insteadOf" config setting (See <xref linkend="git-config(1)" />) and
\r
110 exit without talking to the remote.
\r
120 In addition to the object pointed by it, show the underlying
\r
121 ref pointed by it when showing a symbolic ref. Currently,
\r
122 upload-pack only shows the symref HEAD, so it will be the only
\r
123 one shown by ls-remote.
\r
133 Sort based on the key given. Prefix <emphasis>-</emphasis> to sort in descending order
\r
134 of the value. Supports "version:refname" or "v:refname" (tag names
\r
135 are treated as versions). The "version:refname" sort order can also
\r
136 be affected by the "versionsort.suffix" configuration variable.
\r
137 See <xref linkend="git-for-each-ref(1)" /> for more sort options, but be aware
\r
138 keys like <emphasis>committerdate</emphasis> that require access to the objects
\r
139 themselves will not work for refs whose objects have not yet been
\r
140 fetched from the remote, and will give a <emphasis>missing object</emphasis> error.
\r
149 --server-option=<option>
\r
153 Transmit the given string to the server when communicating using
\r
154 protocol version 2. The given string must not contain a NUL or LF
\r
156 When multiple <emphasis>--server-option=<option></emphasis> are given, they are all
\r
157 sent to the other side in the order listed on the command line.
\r
167 The "remote" repository to query. This parameter can be
\r
168 either a URL or the name of a remote (see the GIT URLS and
\r
169 REMOTES sections of <xref linkend="git-fetch(1)" />).
\r
175 <refs>…
\r
179 When unspecified, all references, after filtering done
\r
180 with --heads and --tags, are shown. When <refs>… are
\r
181 specified, only references matching the given patterns
\r
188 <simplesect id="git-ls-remote(1)__examples">
\r
189 <title>EXAMPLES</title>
\r
190 <screen>$ git ls-remote --tags ./.
\r
191 d6602ec5194c87b0fc87103ca4d67251c76f233a refs/tags/v0.99
\r
192 f25a265a342aed6041ab0cc484224d9ca54b6f41 refs/tags/v0.99.1
\r
193 7ceca275d047c90c0c7d5afb13ab97efdf51bd6e refs/tags/v0.99.3
\r
194 c5db5456ae3b0873fc659c19fafdde22313cc441 refs/tags/v0.99.2
\r
195 0918385dbd9656cab0d1d81ba7453d49bbc16250 refs/tags/junio-gpg-pub
\r
196 $ git ls-remote http://www.kernel.org/pub/scm/git/git.git master seen rc
\r
197 5fe978a5381f1fbad26a80e682ddd2a401966740 refs/heads/master
\r
198 c781a84b5204fb294c9ccc79f8b3baceeb32c061 refs/heads/seen
\r
199 $ git remote add korg http://www.kernel.org/pub/scm/git/git.git
\r
200 $ git ls-remote --tags korg v\*
\r
201 d6602ec5194c87b0fc87103ca4d67251c76f233a refs/tags/v0.99
\r
202 f25a265a342aed6041ab0cc484224d9ca54b6f41 refs/tags/v0.99.1
\r
203 c5db5456ae3b0873fc659c19fafdde22313cc441 refs/tags/v0.99.2
\r
204 7ceca275d047c90c0c7d5afb13ab97efdf51bd6e refs/tags/v0.99.3</screen>
\r
206 <simplesect id="git-ls-remote(1)__see_also">
\r
207 <title>SEE ALSO</title>
\r
208 <simpara><xref linkend="git-check-ref-format(1)" />.</simpara>
\r
210 <simplesect id="git-ls-remote(1)__git">
\r
212 <simpara>Part of the <xref linkend="git(1)" /> suite</simpara>
\r