From: Avery Pennarun <apenwarr@gmail.com>
To: david.hagood@gmail.com
Cc: git@vger.kernel.org
Subject: Re: Making GIT XML aware?
Date: Tue, 1 Sep 2009 14:06:30 +0000 [thread overview]
Message-ID: <32541b130909010706s45031e64ld614802f2b57ce5e@mail.gmail.com> (raw)
In-Reply-To: <fcdc4d8bb3b1ee0b1473a48ed79e7c61.squirrel@localhost>
On Tue, Sep 1, 2009 at 1:57 PM, <david.hagood@gmail.com> wrote:
> However, it seems to me that if there were some way to plug into GIT's
> merging logic, it would be possible to design an XML aware merging tool
> that might help on this (generalizing: if you could have content-aware
> merging libraries you could make all sorts of merges go more smoothly).
> For the specific case of an XML file, if you could have some way to denote
> tags and/or attributes that are "don't cares" you could address problems
> like I am having. You could also theoretically exploit a knowledge of the
> format to better identify what chunks are changes and possibly track
> motion within the files better.
You have a couple of options here, both of which you can read about in
'man gitattributes'.
If you have "don't care" attributes, that's a good sign that you
shouldn't be storing them *at all*. You could use the 'filter'
feature of gitattributes to remove them (or convert them to a
constant) on checkin, and regenerate them on checkout.
As for merging algorithms, you can supply a custom one using the
'merge' gitattribute.
> Absent that, is there a way to tell git "in case of an unresolvable merge
> conflict, don't modify the file but put the other version of the file
> somewhere (e.g. filename.other) so that I can use an external tool to
> resolve the differences"? In this case, EA doesn't know how to use the
> standard conflict tags within a file to extract deltas.
You can apparently override this with the 'merge' attribute as well.
Have fun,
Avery
next prev parent reply other threads:[~2009-09-01 14:31 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-09-01 13:57 Making GIT XML aware? david.hagood
2009-09-01 14:06 ` Avery Pennarun [this message]
2009-09-01 14:25 ` Jakub Narebski
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=32541b130909010706s45031e64ld614802f2b57ce5e@mail.gmail.com \
--to=apenwarr@gmail.com \
--cc=david.hagood@gmail.com \
--cc=git@vger.kernel.org \
/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).