1--all::
2Fetch all remotes.
34
-a::
5--append::
6Append ref names and object names of fetched refs to the
7existing contents of `.git/FETCH_HEAD`. Without this
8option old data in `.git/FETCH_HEAD` will be overwritten.
910
--depth=<depth>::
11Deepen the history of a 'shallow' repository created by
12`git clone` with `--depth=<depth>` option (see linkgit:git-clone[1])
13by the specified number of commits.
1415
ifndef::git-pull[]
16--dry-run::
17Show what would be done, without making any changes.
18endif::git-pull[]
1920
-f::
21--force::
22When 'git fetch' is used with `<rbranch>:<lbranch>`
23refspec, it refuses to update the local branch
24`<lbranch>` unless the remote branch `<rbranch>` it
25fetches is a descendant of `<lbranch>`. This option
26overrides that check.
2728
-k::
29--keep::
30Keep downloaded pack.
3132
ifndef::git-pull[]
33--multiple::
34Allow several <repository> and <group> arguments to be
35specified. No <refspec>s may be specified.
3637
-p::
38--prune::
39After fetching, remove any remote-tracking branches which
40no longer exist on the remote.
41endif::git-pull[]
4243
ifdef::git-pull[]
44--no-tags::
45endif::git-pull[]
46ifndef::git-pull[]
47-n::
48--no-tags::
49endif::git-pull[]
50By default, tags that point at objects that are downloaded
51from the remote repository are fetched and stored locally.
52This option disables this automatic tag following. The default
53behavior for a remote may be specified with the remote.<name>.tagopt
54setting. See linkgit:git-config[1].
5556
ifndef::git-pull[]
57-t::
58--tags::
59Most of the tags are fetched automatically as branch
60heads are downloaded, but tags that do not point at
61objects reachable from the branch heads that are being
62tracked will not be fetched by this mechanism. This
63flag lets all tags and their associated objects be
64downloaded. The default behavior for a remote may be
65specified with the remote.<name>.tagopt setting. See
66linkgit:git-config[1].
6768
--recurse-submodules[=yes|on-demand|no]::
69This option controls if and under what conditions new commits of
70populated submodules should be fetched too. It can be used as a
71boolean option to completely disable recursion when set to 'no' or to
72unconditionally recurse into all populated submodules when set to
73'yes', which is the default when this option is used without any
74value. Use 'on-demand' to only recurse into a populated submodule
75when the superproject retrieves a commit that updates the submodule's
76reference to a commit that isn't already in the local submodule
77clone.
7879
--no-recurse-submodules::
80Disable recursive fetching of submodules (this has the same effect as
81using the '--recurse-submodules=no' option).
8283
--submodule-prefix=<path>::
84Prepend <path> to paths printed in informative messages
85such as "Fetching submodule foo". This option is used
86internally when recursing over submodules.
8788
--recurse-submodules-default=[yes|on-demand]::
89This option is used internally to temporarily provide a
90non-negative default value for the --recurse-submodules
91option. All other methods of configuring fetch's submodule
92recursion (such as settings in linkgit:gitmodules[5] and
93linkgit:git-config[1]) override this option, as does
94specifying --[no-]recurse-submodules directly.
95endif::git-pull[]
9697
-u::
98--update-head-ok::
99By default 'git fetch' refuses to update the head which
100corresponds to the current branch. This flag disables the
101check. This is purely for the internal use for 'git pull'
102to communicate with 'git fetch', and unless you are
103implementing your own Porcelain you are not supposed to
104use it.
105106
--upload-pack <upload-pack>::
107When given, and the repository to fetch from is handled
108by 'git fetch-pack', '--exec=<upload-pack>' is passed to
109the command to specify non-default path for the command
110run on the other end.
111112
ifndef::git-pull[]
113-q::
114--quiet::
115Pass --quiet to git-fetch-pack and silence any other internally
116used git commands. Progress is not reported to the standard error
117stream.
118119
-v::
120--verbose::
121Be verbose.
122endif::git-pull[]
123124
--progress::
125Progress status is reported on the standard error stream
126by default when it is attached to a terminal, unless -q
127is specified. This flag forces progress status even if the
128standard error stream is not directed to a terminal.