1GIT-LS-REMOTE(1)                  Git Manual                  GIT-LS-REMOTE(1)
2
3
4

NAME

6       git-ls-remote - List references in a remote repository
7

SYNOPSIS

9       git ls-remote [--heads] [--tags]  [-u <exec> | --upload-pack <exec>]
10                     [--exit-code] <repository> [<refs>...]
11
12

DESCRIPTION

14       Displays references available in a remote repository along with the
15       associated commit IDs.
16

OPTIONS

18       -h, --heads, -t, --tags
19           Limit to only refs/heads and refs/tags, respectively. These options
20           are not mutually exclusive; when given both, references stored in
21           refs/heads and refs/tags are displayed.
22
23       -u <exec>, --upload-pack=<exec>
24           Specify the full path of git-upload-pack on the remote host. This
25           allows listing references from repositories accessed via SSH and
26           where the SSH daemon does not use the PATH configured by the user.
27
28       --exit-code
29           Exit with status "2" when no matching refs are found in the remote
30           repository. Usually the command exits with status "0" to indicate
31           it successfully talked with the remote repository, whether it found
32           any matching refs.
33
34       --get-url
35           Expand the URL of the given remote repository taking into account
36           any "url.<base>.insteadOf" config setting (See git-config(1)) and
37           exit without talking to the remote.
38
39       <repository>
40           Location of the repository. The shorthand defined in
41           $GIT_DIR/branches/ can be used. Use "." (dot) to list references in
42           the local repository.
43
44       <refs>...
45           When unspecified, all references, after filtering done with --heads
46           and --tags, are shown. When <refs>... are specified, only
47           references matching the given patterns are displayed.
48

EXAMPLES

50           $ git ls-remote --tags ./.
51           d6602ec5194c87b0fc87103ca4d67251c76f233a        refs/tags/v0.99
52           f25a265a342aed6041ab0cc484224d9ca54b6f41        refs/tags/v0.99.1
53           7ceca275d047c90c0c7d5afb13ab97efdf51bd6e        refs/tags/v0.99.3
54           c5db5456ae3b0873fc659c19fafdde22313cc441        refs/tags/v0.99.2
55           0918385dbd9656cab0d1d81ba7453d49bbc16250        refs/tags/junio-gpg-pub
56           $ git ls-remote http://www.kernel.org/pub/scm/git/git.git master pu rc
57           5fe978a5381f1fbad26a80e682ddd2a401966740        refs/heads/master
58           c781a84b5204fb294c9ccc79f8b3baceeb32c061        refs/heads/pu
59           b1d096f2926c4e37c9c0b6a7bf2119bedaa277cb        refs/heads/rc
60           $ echo http://www.kernel.org/pub/scm/git/git.git >.git/branches/public
61           $ git ls-remote --tags public v\*
62           d6602ec5194c87b0fc87103ca4d67251c76f233a        refs/tags/v0.99
63           f25a265a342aed6041ab0cc484224d9ca54b6f41        refs/tags/v0.99.1
64           c5db5456ae3b0873fc659c19fafdde22313cc441        refs/tags/v0.99.2
65           7ceca275d047c90c0c7d5afb13ab97efdf51bd6e        refs/tags/v0.99.3
66

GIT

68       Part of the git(1) suite
69
70
71
72Git 1.8.3.1                       11/19/2018                  GIT-LS-REMOTE(1)
Impressum