Mercurial - convert normal repo to bare repo
Asked Answered
A

1

8

i´ve installed TortoiseHg with Mercurial. Another programmer of our department created a "normal" hg repo a few months ago. Now I have to change this repo into a "bare" one. Is this even possible?

Antung answered 15/12, 2014 at 8:35 Comment(1)
duplicate of #4159226Brownley
D
15

To create a bare repo when cloning use the no update flag when cloning i.e. hg clone --noupdate ...

To convert to a bare repo update to the "null" branch use hg update null

Dignadignified answered 15/12, 2014 at 8:45 Comment(2)
that works fine for me, thank you. "hg update null" on central repo deletes all files, excepting the ".hg" directory.Antung
Good answer! Small detail: null is not a branch, is the changeset before the first changeset you make (the ancestor of the first revision).Verdict

© 2022 - 2024 — McMap. All rights reserved.