git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Elijah Newren <newren@gmail.com>
Cc: Brent Goodrick <bgoodr@gmail.com>, git@vger.kernel.org
Subject: Re: How do I force git to forget about merging a binary file that is to stay deleted on the target branch?
Date: Sat, 28 Mar 2009 08:07:24 -0700	[thread overview]
Message-ID: <7viqltvg7n.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <51419b2c0903280547y1bb5664dj70e4e6aa939bd015@mail.gmail.com> (Elijah Newren's message of "Sat, 28 Mar 2009 06:47:38 -0600")

Elijah Newren <newren@gmail.com> writes:

> On Fri, Mar 27, 2009 at 11:26 PM, Brent Goodrick <bgoodr@gmail.com> wrote:
>> How do I commit a merge but force git to forget about merging one file
>> that I don't want on the target branch, when it is binary, and when it
>> was changed on the source branch, but was deleted on the target branch
>> (and should stay deleted on the target branch)?
>>
>> The details: I am merging a "work" branch into a "home" branch.  There
>> is one file called "TimeSheets/Timesheet Exempt.XLS" that is binary.
>> I don't want that file on the "home" branch, but do want it on the
>> "work" branch.  I had made an editing change to that file on the
>> "work" branch, along with a bunch of other changes I do want to merge
>> into the "home" branch. But no matter what I do, I can't force git to
>> forget about that "TimeSheets/Timesheet Exempt.XLS" file.
>>
>> I've tried various flavors of git-checkout and git-reset to no
>> avail. This is what I see at the very last before I gave up:
>
> You can resolve this merge conflict by running
> $ git rm TimeSheets/Timesheet\ Exempt.XLS
>
> which will make git delete the file from your working copy and the
> index, at which point you can then make a commit that does not include
> this file.

But is this what you really want to do?  After doing such a "remove it"
merge resolution at Home, wouldn't merging it back to Work remove the
file?

  parent reply	other threads:[~2009-03-28 15:09 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-03-28  5:26 How do I force git to forget about merging a binary file that is to stay deleted on the target branch? Brent Goodrick
2009-03-28 10:23 ` Nanako Shiraishi
2009-03-28 14:29   ` Brent Goodrick
2009-03-28 12:47 ` Elijah Newren
2009-03-28 14:46   ` Brent Goodrick
2009-03-28 15:07   ` Junio C Hamano [this message]
2009-03-28 15:21     ` Brent Goodrick

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7viqltvg7n.fsf@gitster.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=bgoodr@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=newren@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).