Jeff King <peff@xxxxxxxx> writes: > On Tue, Sep 17, 2013 at 03:00:41PM -0700, Junio C Hamano wrote: > >> > So given that, is it fair to say that a one-way "go here" merge, limited >> > by pathspec, is the closest equivalent? >> >> Sorry, but it is unclear to me what you mean by one-way "go here" >> merge. Do you mean oneway_merge() in unpack-trees.c? > > Yes, that is what I meant. Yeah, then I agree that "git checkout HEAD^ -- subdir" should be a one-way "go HEAD^" merge limited only to the paths that match subdir/. If implemented in a straight-forward way, I suspect that we may end up not removing subdir/b in Uwe's sample transcript. I am not sure if that is a good thing or not, though. If the index originally tracked and then "going to" tree does not, I think removing it would match "ignore local modifications" rule, as subdir/a that is tracked in the index and also in "going to" tree does get overwritten to match the state recorded in the tree. -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html