From: Junio C Hamano Date: Tue, 24 Feb 2009 06:31:10 GMT Subject: Re: how do I resolve this merge manually + mergetool bug Message-ID: <7vbpssmjm9.fsf@gitster.siamese.dyndns.org> In-Reply-To: <81bfc67a0902232204y7a1e9a91x6cbf751319664734@mail.gmail.com> Caleb Cushing writes: > # unmerged: profiles/package.mask > > on the remote package.mask is a file locally it is a directory. > ... > git rm :3:profiles/package.mask > fatal: pathspec ':3:profiles/package.mask' did not match any files The answer most likely is this but don't do this just yet: $ git rm profiles/package.mask With this, you are saying "For the path profiles/package.mask, the correct resolution is not to have it". There is no room for the stage number to get into the picture when you are talking about the final result. But I am suspecting that this is because you moved it to somewhere (perhaps to profiles/package.mask/frotz) while the remote side kept it intact or modified it in place. If that is the case, and if the remote side made an in-place change, you would want to port the change over to the path you moved the contents to before you actually remove it, so before running the above "git rm", I would do something like. $ git cat-file blob :1:profiles/package.mask >original $ git cat-file blob :3:profiles/package.mask >theirs $ git cat-file blob profiles/package.mask/frotz >mine $ git merge-file mine original theirs $ diff -u profiles/package.mask/frotz mine ;# eyeball the merge result $ cat mine >profiles/package.mask/frotz and then finally conclude the merge with: $ git rm profiles/package.mask $ git add profiles/package.mask/frotz But if the remote side did not change anything (i.e. original == theirs), then you do not have to do the file-level merge to update the contents you moved to a different path.