git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Pawel Por <porparek@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: git stash merge
Date: Mon, 20 Apr 2015 11:12:50 -0700	[thread overview]
Message-ID: <xmqqy4lmllct.fsf@gitster.dls.corp.google.com> (raw)
In-Reply-To: <CAJmOuEwEgA-9NCtBXjij-rLhsCWMyw+DcRVGo4=0b1V2nC==cA@mail.gmail.com> (Pawel Por's message of "Mon, 20 Apr 2015 18:36:02 +0200")

Pawel Por <porparek@gmail.com> writes:

> I've just upgraded the linux kernel git source tree and I want to
> "pop" my stashed work. I do the following:
> git stash pop
>
> and I got the following message:
> mm/Makefile: needs merge
> unable to refresh index

The symptom indicates that "upgraded the linux kernel git source
tree" has not been cleanly completed and has an unmerged entry in
the index.  That is the first thing "stash pop" tries to check that
the source tree does not have any pending change that does not have
anything to do with your application of the stash, and you seem to
be triggering that safety check.

If your working tree does not have changes of any value, perhaps
"git reset --hard && git pull" (or you may even want to resort to
"git fetch && git reset --hard origin") to make sure "upgraded the
source tree" part truly has cleanly completed may be a good second
step to get "stash pop" going.  The good first step is to see what
local changes you have, of course---perhaps your "upgraded the linux
kernel git source tree" conflicted with your local changes that you
need to resolve first.

      reply	other threads:[~2015-04-20 18:12 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-20 16:36 git stash merge Pawel Por
2015-04-20 18:12 ` Junio C Hamano [this message]

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=xmqqy4lmllct.fsf@gitster.dls.corp.google.com \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=porparek@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).