Re: Segfault with merge-tree on multiple Git versions
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Mar 27, 2013, 20:04 UTC
- Message-ID
- <7vtxnwlidq.fsf@alter.siamese.dyndns.org>
- In-Reply-To
- <20130327194521.GQ2286@serenity.lan>
John Keeping <john@keeping.me.uk> writes:
Show 9 quoted lines
> You could use a temporary index and do something like: > > rm -f TMP_INDEX > GIT_INDEX_FILE=TMP_INDEX > export GIT_INDEX_FILE > git read-tree -m $base $ours $theirs && > git merge-index git-merge-one-file -a > > then inspect that with "git diff-index --cached $ours".
Good.
> Note that this will fail if there are conflicts and I don't know what > git-merge-tree will do in that case.
I _think_ Charlies's use case is to detect trivial merges to tell the requestee that a merge request can be done on site, so failing is fine when there are conflicts. merge-tree should report conflicts as well.