From: Tim Visher <tim.visher@gmail.com>
To: Dale Rowley <ddrowley@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: rebase --continue confusion
Date: Sun, 30 May 2010 08:44:29 -0400 [thread overview]
Message-ID: <AANLkTika8osPqvlcZKqVTMN5IwLxBZioBCD1NgLHj0EQ@mail.gmail.com> (raw)
In-Reply-To: <4C01B855.7080409@gmail.com>
On Sat, May 29, 2010 at 8:59 PM, Dale Rowley <ddrowley@gmail.com> wrote:
> I ran into a conflict while running 'git rebase branch1 branch2'. So I edited
> the file and resolved the conflicts, and then ran 'git add <file>; git rebase
> --continue'. This printed out a message 'No changes - did you forget to use git
> add?'. I thought 'No, I'm pretty sure I ran git add' and I assumed I had run
> into a bug in git because I didn't see how this conflict was different than any
> others I had successfully resolved. The next time this problem came up, the
> light finally came on and I realized that I should just run 'git rebase --skip'
> because when I resolved the conflicts, I had basically undone all changes that
> the patch would introduce.
>
> OK, so there isn't a bug in git, but since then I've seen co-workers stumped by
> this same problem. So maybe it would help to clarify the message? Maybe
> something like "The index is in the same state as it was before the patch was
> applied - refusing to make an empty commit. Did you forget to use 'git add'? Or
> maybe you should use 'git rebase --skip'?"
2 things.
1. I agree that the message could be more informative, especially
given the context. If the the patch looks exactly like the last patch
applied now that you've edited it during a rebase, it would _almost_
be safe to assume that you meant to skip and just didn't know you were
going to before hand.
2. `git status` should show you that you had nothing to commit, which
would completely explain why `git rebase --continue` threw out the
message it did. I'm in the habit of running `git st` continually and
it often helps me catch this sort of thing where I thought I'd added
something to the index or forgot that I'd changed some file between
the last time I'd updated the index or something along those lines.
This is just sort of a recommendation on a way to modify your work
flow that may help you and your coworkers in the future. YMMV.
--
In Christ,
Timmy V.
http://burningones.com/
http://five.sentenc.es/ - Spend less time on e-mail
next prev parent reply other threads:[~2010-05-30 12:45 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-05-30 0:59 rebase --continue confusion Dale Rowley
2010-05-30 12:44 ` Tim Visher [this message]
2010-05-31 0:14 ` skillzero
[not found] ` <20100530101926.3bac34c8jk@jk.gs@perceptron>
2010-05-31 19:31 ` [PATCH] git-am: suggest what to do with superfluous patches Junio C Hamano
2010-05-31 20:17 ` Ramkumar Ramachandra
2010-05-31 22:51 ` Jan Krüger
2010-06-06 13:10 ` rebase --continue confusion Eli Barzilay
2010-06-06 22:18 ` Jeff King
2010-06-06 22:32 ` Eli Barzilay
2010-06-06 22:46 ` Jeff King
2010-06-06 23:42 ` Eli Barzilay
2010-06-07 0:41 ` Jeff King
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=AANLkTika8osPqvlcZKqVTMN5IwLxBZioBCD1NgLHj0EQ@mail.gmail.com \
--to=tim.visher@gmail.com \
--cc=ddrowley@gmail.com \
--cc=git@vger.kernel.org \
/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).