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

Re: [PATCH v3] worktree: add 'list' command

From
David Turner <dturner@twopensource.com>
Date
Aug 11, 2015, 02:55 UTC
Message-ID
<1439261725.5283.9.camel@twopensource.com>
In-Reply-To
<1439239982-42826-2-git-send-email-rappazzo@gmail.com>
On Mon, 2015-08-10 at 16:53 -0400, Michael Rappazzo wrote:
> +			while ((d = readdir(dir)) != NULL) {

I think it would be useful to break this loop out into a for_each_worktree function.

While looking into per-worktree ref stuff, I have just noticed that git prune will delete objects that are only referenced in a different worktree's detached HEAD. To fix this, git prune will need to walk over each worktree, looking at that worktree's HEAD (and other per-worktree refs). It would be useful to be able to reuse some of this code for that task.

Previous: Junio C HamanoNext: Mike Rappazzo
Message 6 of 8 in “worktree: add 'list' command”
  1. worktree: add 'list' commandMichael Rappazzo, Aug 10, 2015
  2. worktree: add 'list' commandMichael Rappazzo, Aug 10, 2015
  3. Junio C HamanoAug 10, 2015
  4. Mike RappazzoAug 11, 2015
  5. Junio C HamanoAug 11, 2015
  6. David TurnerAug 11, 2015
  7. Mike RappazzoAug 11, 2015
  8. Junio C HamanoAug 11, 2015

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.