diff options
author | Junio C Hamano <junkio@cox.net> | 2006-01-14 16:00:32 -0800 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2006-01-14 16:00:32 -0800 |
commit | 8a1a120c55a67c3193e136a06826585711717399 (patch) | |
tree | 8cbd02f601da577c1f59ad479bb9eda73087405d /Documentation/git-clone.txt | |
parent | 9e9b26751a5ca7a257b3e1cfb319fe3e4efc663c (diff) | |
download | git-8a1a120c55a67c3193e136a06826585711717399.tar.gz git-8a1a120c55a67c3193e136a06826585711717399.tar.xz |
clone: --naked option.
The new option --naked is to help creating a naked repository
for public consumption.
$ git clone -l -s --naked \
/pub/scm/.../torvalds/linux-2.6.git subproj-2.6.git
is equivalent to this sequence:
$ git clone -l -s -n /pub/scm/.../torvalds/linux-2.6.git temp
$ mv temp/.git subproj-2.6.git
$ rmdir temp
Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'Documentation/git-clone.txt')
-rw-r--r-- | Documentation/git-clone.txt | 24 |
1 files changed, 23 insertions, 1 deletions
diff --git a/Documentation/git-clone.txt b/Documentation/git-clone.txt index 790b87b23..8488202e3 100644 --- a/Documentation/git-clone.txt +++ b/Documentation/git-clone.txt @@ -9,7 +9,7 @@ git-clone - Clones a repository. SYNOPSIS -------- [verse] -'git-clone' [-l [-s]] [-q] [-n] [-o <name>] [-u <upload-pack>] +'git-clone' [-l [-s]] [-q] [-n] [--naked] [-o <name>] [-u <upload-pack>] <repository> [<directory>] DESCRIPTION @@ -58,6 +58,12 @@ OPTIONS -n:: No checkout of HEAD is performed after the clone is complete. +--naked:: + Make a 'naked' GIT repository. That is, instead of + creating `<directory>` and placing the administrative + files in `<directory>/.git`, make the `<directory>` + itself the `$GIT_DIR`. This implies `-n` option. + -o <name>:: Instead of using the branch name 'origin' to keep track of the upstream repository, use <name> instead. Note @@ -103,6 +109,22 @@ $ cd copy $ git show-branch ------------ + +Create a naked repository to publish your changes to the public:: ++ +------------ +$ git clone --naked -l /home/proj/.git /pub/scm/proj.git +------------ + + +Create a repository on the kernel.org machine that borrows from Linus:: ++ +------------ +$ git clone --naked -l -s /pub/scm/.../torvalds/linux-2.6.git \ + /pub/scm/.../me/subsys-2.6.git +------------ + + Author ------ Written by Linus Torvalds <torvalds@osdl.org> |