On 27 June 2013 18:55, Yann Dirson <dir...@bertin.fr> wrote:
> I just ran into a funny edge-case when doing a long rebase: one of
> the rewritten commits got a sha1 starting with one of the abbreviated
> sha1's of a commit still to be applied.
> As a result, the rebase stopped with a funny-looking "short SHA1 ... was
> ambiguous", which would not have occured if the shortened sha1's presented
> to the user were expanded to full sha1's before starting the rebase.

I do many large rebases, and I have experienced this about a dozen times
in the last few years.

I'm not sure that rebase could predict the new hashes without actually creating
the prior commits? So maybe the "short" SHA1 is "too short"?

When the rebase stops with this message, my workaround is:

The last (failed) entry is in .git/rebase-merge/done
The next todo is the top entry in .git/rebase-merge/git-rebase-todo
I enter the short SHA1 in gitk to find the long SHA1.
I edit both the above files to move the failed entry back into the top
of the todo file, with the long SHA1
And then git rebase --continue
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to