git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Michael Haggerty <mhagger@alum.mit.edu>
To: David Turner <dturner@twopensource.com>,
	git@vger.kernel.org, pclouds@gmail.com, chriscool@tuxfamily.org
Subject: Re: [PATCH/RFC 0/2] bisect per-worktree
Date: Sat, 01 Aug 2015 05:59:52 +0200	[thread overview]
Message-ID: <55BC4438.8060709@alum.mit.edu> (raw)
In-Reply-To: <1438387012-29229-1-git-send-email-dturner@twopensource.com>

On 08/01/2015 01:56 AM, David Turner wrote:
> This is RFC because I'm not sure why show-ref only works on refs/ (and
> whether it should learn to look in worktree-refs/).  I'm also not sure
> whether there are other changes I should make to refs.c to handle
> per-worktree refs; I basically did the simplest thing I could think of
> to start with.

It seems to me that adding a new top-level "worktree-refs" directory is
pretty traumatic. Lots of people and tools will have made the assumption
that all "normal" references live under "refs/".

Each worktree has a name, right? What if worktree-specific refs were
stored under "refs/worktree/<name>/" or something? This would require
the name to be a valid reference name component, but I think that is a
prudent idea anyway.

Of course that doesn't answer the question: where should the refs for
the main repository go? I suppose either in the current place, or maybe
the main repository should have a name too (e.g. "main") and its
references should be stored under "refs/worktree/main/".

These worktree-specific refs should presumably be deleted automatically
when the worktree is deleted.

Either way, there's also the question of who should know how to find the
worktree-specific references--the program that wants to access them, or
should there be a secret invisible mapping that is done on lookup, and
that knows the full list of references that want to be worktree-specific
(for example, that in a linked worktree, "refs/bisect/*" should be
silently redirected to "refs/worktree/<name>/bisect/*")?

It's all a bit frightening, frankly.

Michael

-- 
Michael Haggerty
mhagger@alum.mit.edu

  parent reply	other threads:[~2015-08-01  4:00 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-31 23:56 [PATCH/RFC 0/2] bisect per-worktree David Turner
2015-07-31 23:56 ` [PATCH 1/2] refs: workree-refs/* become per-worktree David Turner
2015-07-31 23:56 ` [PATCH 2/2] bisect: make bisection refs per-worktree David Turner
2015-08-01  3:59 ` Michael Haggerty [this message]
2015-08-01  5:12   ` [PATCH/RFC 0/2] bisect per-worktree Junio C Hamano
2015-08-01  5:55     ` David Turner
2015-08-01  6:51     ` Michael Haggerty
2015-08-02 18:24       ` Junio C Hamano
2015-08-03 12:35       ` Duy Nguyen
2015-08-03 19:49       ` David Turner
2015-08-03 21:14         ` Junio C Hamano
2015-08-03 23:09         ` Duy Nguyen
2015-08-03 23:20           ` David Turner
2015-08-03 13:02   ` Duy Nguyen
2015-08-03 14:03     ` Duy Nguyen
     [not found] <CAP8UFD0aCSW3JxneHvSEE3T6zQtgipp5nhWT9VpMqHAmzd_e3Q@mail.gmail.com>
2015-08-01  5:43 ` David Turner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=55BC4438.8060709@alum.mit.edu \
    --to=mhagger@alum.mit.edu \
    --cc=chriscool@tuxfamily.org \
    --cc=dturner@twopensource.com \
    --cc=git@vger.kernel.org \
    --cc=pclouds@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).