@matheusbsbs / matheus-bagliano / commits / f4bf2184ae
Fork 0

Update clone/fetch documentation with --depth (shallow clone) option

Signed-off-by: Junio C Hamano <junkio@cox.net>

Junio C Hamano committed Jan 1, 2007 at 15:08 UTC f4bf2184ae8b79f95b9f56c1ea5455d04e559299
2 files changed +16 -1
Documentation/fetch-options.txt
+5
@@ -41,3 +41,8 @@
41 implementing your own Porcelain you are not supposed to
42 use it.
43
44 +\--depth=<depth>::
45 + Deepen the history of a 'shallow' repository created by
46 + `git clone` with `--depth=<depth>` option (see gitlink:git-clone[1])
47 + by the specified number of commits.
48 +
Documentation/git-clone.txt
+11 -1
@@ -11,7 +11,7 @@ SYNOPSIS
11 [verse]
12 'git-clone' [--template=<template_directory>] [-l [-s]] [-q] [-n] [--bare]
13 [-o <name>] [-u <upload-pack>] [--reference <repository>]
14 - <repository> [<directory>]
14 + [--depth=<depth>] <repository> [<directory>]
15
16 DESCRIPTION
17 -----------
@@ -31,6 +31,7 @@ the remote branch heads under `$GIT_DIR/refs/remotes/origin` and
31 by initializing `remote.origin.url` and `remote.origin.fetch`
32 configuration variables.
33
34 +
35 OPTIONS
36 -------
37 --local::
@@ -95,6 +96,15 @@ OPTIONS
96 if unset the templates are taken from the installation
97 defined default, typically `/usr/share/git-core/templates`.
98
99 +--depth=<depth>::
100 + Create a 'shallow' clone with a history truncated to the
101 + specified number of revs. A shallow repository has
102 + number of limitations (you cannot clone or fetch from
103 + it, nor push from nor into it), but is adequate if you
104 + want to only look at near the tip of a large project
105 + with a long history, and would want to send in a fixes
106 + as patches.
107 +
108 <repository>::
109 The (possibly remote) repository to clone from. It can
110 be any URL git-fetch supports.