From: Johan Herland <johan@herland.net>
To: Junio C Hamano <gitster@pobox.com>
Cc: git@vger.kernel.org
Subject: Re: 'git notes merge' implementation questions
Date: Thu, 22 Apr 2010 10:38:25 +0200 [thread overview]
Message-ID: <201004221038.25487.johan@herland.net> (raw)
In-Reply-To: <7vzl0w730b.fsf@alter.siamese.dyndns.org>
On Thursday 22 April 2010, Junio C Hamano wrote:
> Johan Herland <johan@herland.net> writes:
> > Next, we will need to be somewhat careful about using "ls-tree", to
> > avoid needlessly unpacking subtrees that are identical between <ours>
> > and <theirs>.
>
> My mentioning of "ls-tree" is only about what needs to be done at the
> conceptual level. In practice, assuming that notes trees have mostly the
> same fan-out structure, you would run "diff-tree -r" of (base,ours) and
> (base,theirs) pair _without_ anything fancy like rename detection, and
> pick out pieces (one tree may have ab/cdx{36} while the other tree may
> have abcd/x{36} that are notes about the same object---you treat this as
> if it is a partial ls-tree output that pertains only to the different
> parts, and make canonical "list of annotated objects" by removing '/'.
Got it. Brilliant, and obvious, really, when I think about it...
> All of this is very specific to merging "notes" and normal "merge" does
> not even want to know about it; I don't think you can avoid doing this
> yourself without touching "merge" if you want to merge "notes" correctly.
Agreed. From your feedback, I now have a much clearer picture on how to
proceed. Thanks! :)
Have fun!
...Johan
--
Johan Herland, <johan@herland.net>
www.herland.net
prev parent reply other threads:[~2010-04-22 8:38 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-21 7:57 'git notes merge' implementation questions Johan Herland
2010-04-21 17:12 ` Jonathan Nieder
2010-04-21 23:55 ` Johan Herland
2010-04-22 0:26 ` Jonathan Nieder
2010-04-21 21:29 ` Junio C Hamano
2010-04-22 0:08 ` Johan Herland
2010-04-22 0:12 ` Junio C Hamano
2010-04-22 8:34 ` Johan Herland
2010-04-22 0:19 ` Junio C Hamano
2010-04-22 8:38 ` Johan Herland [this message]
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=201004221038.25487.johan@herland.net \
--to=johan@herland.net \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.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).