Update clone/fetch documentation with --depth (shallow clone) option
Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
@ -41,3 +41,8 @@
|
|||||||
implementing your own Porcelain you are not supposed to
|
implementing your own Porcelain you are not supposed to
|
||||||
use it.
|
use it.
|
||||||
|
|
||||||
|
\--depth=<depth>::
|
||||||
|
Deepen the history of a 'shallow' repository created by
|
||||||
|
`git clone` with `--depth=<depth>` option (see gitlink:git-clone[1])
|
||||||
|
by the specified number of commits.
|
||||||
|
|
||||||
|
@ -11,7 +11,7 @@ SYNOPSIS
|
|||||||
[verse]
|
[verse]
|
||||||
'git-clone' [--template=<template_directory>] [-l [-s]] [-q] [-n] [--bare]
|
'git-clone' [--template=<template_directory>] [-l [-s]] [-q] [-n] [--bare]
|
||||||
[-o <name>] [-u <upload-pack>] [--reference <repository>]
|
[-o <name>] [-u <upload-pack>] [--reference <repository>]
|
||||||
<repository> [<directory>]
|
[--depth=<depth>] <repository> [<directory>]
|
||||||
|
|
||||||
DESCRIPTION
|
DESCRIPTION
|
||||||
-----------
|
-----------
|
||||||
@ -31,6 +31,7 @@ the remote branch heads under `$GIT_DIR/refs/remotes/origin` and
|
|||||||
by initializing `remote.origin.url` and `remote.origin.fetch`
|
by initializing `remote.origin.url` and `remote.origin.fetch`
|
||||||
configuration variables.
|
configuration variables.
|
||||||
|
|
||||||
|
|
||||||
OPTIONS
|
OPTIONS
|
||||||
-------
|
-------
|
||||||
--local::
|
--local::
|
||||||
@ -95,6 +96,15 @@ OPTIONS
|
|||||||
if unset the templates are taken from the installation
|
if unset the templates are taken from the installation
|
||||||
defined default, typically `/usr/share/git-core/templates`.
|
defined default, typically `/usr/share/git-core/templates`.
|
||||||
|
|
||||||
|
--depth=<depth>::
|
||||||
|
Create a 'shallow' clone with a history truncated to the
|
||||||
|
specified number of revs. A shallow repository has
|
||||||
|
number of limitations (you cannot clone or fetch from
|
||||||
|
it, nor push from nor into it), but is adequate if you
|
||||||
|
want to only look at near the tip of a large project
|
||||||
|
with a long history, and would want to send in a fixes
|
||||||
|
as patches.
|
||||||
|
|
||||||
<repository>::
|
<repository>::
|
||||||
The (possibly remote) repository to clone from. It can
|
The (possibly remote) repository to clone from. It can
|
||||||
be any URL git-fetch supports.
|
be any URL git-fetch supports.
|
||||||
|
Reference in New Issue
Block a user