From: Junio C Hamano Date: Tue, 14 Feb 2006 02:28:00 GMT Subject: Re: maildir / read-tree trivial merging getting in the way? Message-ID: <7vy80ewu6n.fsf@assigned-by-dhcp.cox.net> In-Reply-To: Ben Clifford writes: > So basically my question is: should I feel dirty about doing this and > diddle read-tree so that there's a flag to not do the trivial merges > automatically? I am mildly negative about touching read-tree for this kind of non-SCM'ish usage. If you are doing read-tree without doing any trivial merge, then you would use ls-files to inspect each stage, decide what the final shape of the tree you want, and construct such a tree in the index. That would be more naturally done by writing that thing in a more reasonable scripting language (not shell, but Perl or Python), call ls-tree three times, do whatever merge to come up with the final shape of the tree, and then construct the tree with a single invocation of "update-index --index-info", maybe even starting from an empty index file.