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

[git-new-workdir RFC] Backlinking $workdir/logs/HEAD to $GIT_DIR/logs/workdir?

From
Adeodato Simó <dato@net.com.org.es>
Date
Dec 27, 2008, 12:15 UTC
Message-ID
<20081227121526.GA12120@chistera.yi.org>
Hello,

I use git new-workdir for some of my projects. Apart from the usual caveat "don't checkout the same branch twice", I found another small issue, surely known: the reflog for HEAD in the workidirs does not exist in the source git repo, hence git-gc will happily prune what it believes to be dangling commits.

Would it be, perhaps, be okay to create a logs/workdir/<name>/HEAD symlink pointing to $workdir/logs/HEAD, so that this does not happen?

Comments welcome.
-- 
Adeodato Simó                                     dato at net.com.org.es
Debian Developer                                  adeodato at debian.org
 
                                            Listening to: Niza - Parasol
Next: Shawn O. Pearce
Message 1 of 2 in “[git-new-workdir RFC] Backlinking $workdir/logs/HEAD to $GIT_DIR/logs/workdir?”
  1. Adeodato SimóDec 27, 2008
  2. Shawn O. PearceDec 27, 2008

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.