Re: Make a non-bare repo bare.
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jul 16, 2009, 20:47 UTC
- Message-ID
- <7vd4808iey.fsf@alter.siamese.dyndns.org>
- In-Reply-To
- <e2b179460907160155g7c84b083u8a1dd6ba193f4531@mail.gmail.com>
Mike Ralphson <mike.ralphson@gmail.com> writes:
Show 19 quoted lines
> 2009/7/16 Graeme Geldenhuys <graemeg@gmail.com>: >> Junio C Hamano wrote: >>> >>> Funny. >>> >>> http://article.gmane.org/gmane.comp.version-control.git/123303 >>> >>> It is posed as a question but describes the correct (and officially >>> supported) procedure. >> >> >> Now it deserves to be in some Git FAQ. It seems the issue is more common >> than I thought. :-) > > It already is > > http://git.or.cz/gitwiki/GitFaq#HowdoImakeexistingnon-barerepositorybare.3F > > unless that's new?
Somebody needs to promise to keep that entry up-to-date, or we should rewrite it so that we do not expose such an implementation detail.
Even today core.bare is not the only difference between a repository with a work tree and a bare one. We also set core.logallrefupdates these days for a repository with a work tree, so the procedure described there is already stale. And this kind of implementation details are bound to change.
Asking git what to do is the only reliable "cut-and-paste-ready" recipe.