mirror of
https://github.com/git/git
synced 2024-08-25 02:35:46 +00:00
Merge branch 'ss/clone-depth-single-doc' into maint
Documentation for "git fetch --depth" has been updated for clarity. * ss/clone-depth-single-doc: docs: clarify that --depth for git-fetch works with newly initialized repos docs: say "commits" in the --depth option wording for git-clone docs: clarify that passing --depth to git-clone implies --single-branch
This commit is contained in:
commit
2db7d79be9
|
@ -8,10 +8,11 @@
|
||||||
option old data in `.git/FETCH_HEAD` will be overwritten.
|
option old data in `.git/FETCH_HEAD` will be overwritten.
|
||||||
|
|
||||||
--depth=<depth>::
|
--depth=<depth>::
|
||||||
Deepen or shorten the history of a 'shallow' repository created by
|
Limit fetching to the specified number of commits from the tip of
|
||||||
`git clone` with `--depth=<depth>` option (see linkgit:git-clone[1])
|
each remote branch history. If fetching to a 'shallow' repository
|
||||||
to the specified number of commits from the tip of each remote
|
created by `git clone` with `--depth=<depth>` option (see
|
||||||
branch history. Tags for the deepened commits are not fetched.
|
linkgit:git-clone[1]), deepen or shorten the history to the specified
|
||||||
|
number of commits. Tags for the deepened commits are not fetched.
|
||||||
|
|
||||||
--unshallow::
|
--unshallow::
|
||||||
If the source repository is complete, convert a shallow
|
If the source repository is complete, convert a shallow
|
||||||
|
|
|
@ -190,15 +190,14 @@ objects from the source repository into a pack in the cloned repository.
|
||||||
|
|
||||||
--depth <depth>::
|
--depth <depth>::
|
||||||
Create a 'shallow' clone with a history truncated to the
|
Create a 'shallow' clone with a history truncated to the
|
||||||
specified number of revisions.
|
specified number of commits. Implies `--single-branch` unless
|
||||||
|
`--no-single-branch` is given to fetch the histories near the
|
||||||
|
tips of all branches.
|
||||||
|
|
||||||
--[no-]single-branch::
|
--[no-]single-branch::
|
||||||
Clone only the history leading to the tip of a single branch,
|
Clone only the history leading to the tip of a single branch,
|
||||||
either specified by the `--branch` option or the primary
|
either specified by the `--branch` option or the primary
|
||||||
branch remote's `HEAD` points at. When creating a shallow
|
branch remote's `HEAD` points at.
|
||||||
clone with the `--depth` option, this is the default, unless
|
|
||||||
`--no-single-branch` is given to fetch the histories near the
|
|
||||||
tips of all branches.
|
|
||||||
Further fetches into the resulting repository will only update the
|
Further fetches into the resulting repository will only update the
|
||||||
remote-tracking branch for the branch this option was used for the
|
remote-tracking branch for the branch this option was used for the
|
||||||
initial cloning. If the HEAD at the remote did not point at any
|
initial cloning. If the HEAD at the remote did not point at any
|
||||||
|
|
Loading…
Reference in a new issue