Posted on Leave a comment

Duplicating (mirroring) a repository

To make an exact duplicate, you need to perform both a bare-clone and a mirror-push.

[code language=”java”]
git clone –bare <reponame>
# Make a bare clone of the repository

cd <reponame>
git push –mirror <newreponame>
# Mirror-push to the new repository
[/code]

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.