Omer Dagan
Omer Dagan

Reputation: 15976

How to git clone from *local bare* repository

Say I have a bare repository on my local machine at ./new-bare.git. What is the correct way to clone it to another location on my machine?

Upvotes: 12

Views: 15177

Answers (2)

frlan
frlan

Reputation: 7260

There is no difference in cloning from a not bare repository:

/tmp> mkdir foo
/tmp> git init --bare foo 
Initialized empty Git repository in /tmp/foo/
/tmp> git clone /tmp/foo /tmp/baa
Cloning into '/tmp/baa'...
warning: You appear to have cloned an empty repository.
done.

Upvotes: 21

Shravan40
Shravan40

Reputation: 9888

git clone path_to_new-bare.git new_destination

Upvotes: 8

Related Questions