Web lists-archives.com

Re: [PATCH v4 0/2] Fix scissors bug during merge conflict

Denton Liu <liu.denton@xxxxxxxxx> writes:

> I just realised that there is a slight problem with the proposed change.
> When we do a merge and there are no merge conflicts, at the end of the
> merge, we get dropped into an editor with this text:
> 	Merge branch 'master' into new
> 	# Please enter a commit message to explain why this merge is necessary,
> 	# especially if it merges an updated upstream into a topic branch.
> 	#
> 	# Lines starting with '#' will be ignored, and an empty message aborts
> 	# the commit.
> Note that in git-merge, the cleanup only removes commented lines and
> this cannot be configured to be scissors or whatever else. I think that
> the fact that it's not configurable isn't a problem; most hardcore
> commit message editing happens in git-commit anyway.


> However, since we taught git-merge the --cleanup option, this might be
> misleading for the end-user since they would expect the MERGE_MSG to be
> cleaned up as specified.
> I see two resolutions for this. We can either rename --cleanup more
> precisely so users won't be confused (perhaps something like
> --merge-conflict-scissors but a lot more snappy) or we can actually make
> git-merge respect the cleanup option and post-process the message
> according to the specified cleanup rule.

The former certainly would be simpler to implement, but feels more
like an excuse for not doing the right thing to me, when I put
myself in shoes of users who use 'scissors' clean-up option in
commit.  I dunno.