Mirroring Git repos
Here is a quick way to mirror a git repo from one remote to another. This is not only useful for mirroring but also for backups.
git clone --mirror email@example.com/myuser/myrepo.git command will create a mirrored repo, which
is pretty much like a
bare repo, but it also maps all local branches to the remote branches and gets all the refs (like tags).
Basically a one to one copy of the remote repo.
Then it can be pushed to the new remote with
git push --mirror firstname.lastname@example.org/myuser/myrepo.git.
If you ever need to update the local clone with commits from the old remote (or the new one) it can be done
git fetch --all.
And done, a nice easy way to move entire repos.