git/list[1] front-page[2] threads[3] people[4] search[5] about
 

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.
Previous: Mike RalphsonNext: Sitaram Chamarty
Message 8 of 13 in “Make a non-bare repo bare.”
  1. Tim VisherJul 15, 2009
  2. Paolo BonziniJul 15, 2009
  3. Tim VisherJul 16, 2009
  4. Jeff KingJul 16, 2009
  5. Junio C HamanoJul 16, 2009
  6. Graeme GeldenhuysJul 16, 2009
  7. Mike RalphsonJul 16, 2009
  8. Junio C HamanoJul 16, 2009
  9. Sitaram ChamartyJul 17, 2009
  10. Sitaram ChamartyJul 16, 2009
  11. Tim VisherJul 16, 2009
  12. Junio C HamanoJul 16, 2009
  13. Sitaram ChamartyJul 17, 2009

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.