tags:

views:

64

answers:

1

the players:

master: the svn branch (actual, not local trackign) mybranch: a local branch

My mistake:

[master] git svn rebase
[master] git merge mybranch
[master] git svn dcommit

I did this twice.

Is there a way I can remedy all this? I was thinking something like:

  1. git checkout --hard [commit before the merging]
  2. git dcommit # that to the svn?
  3. git rebase mybranch
  4. git dcommit

But this doesn't seem to work.

(I know I should a. working from a local tracking branch and b. have rebased rather than merged)

I'm in the frantic / willing to send beer to respondents stage :)

A: 

Since rewriting history on the SVN side is hard, why not try dcommit a new commit which effectively cancel what you have previously dcommitted twice?

git log # grab the commit hash you want to revert
git revert <commit hash>
git svn dcommit

git revert

Given one existing commit, revert the change the patch introduces, and record a new commit that records it.

VonC
Not really what i'm looking for, but I have my problem solved-ish. I'm not worried about rewriting svn history... just trying to *additionally* get the history I lost into svn. Ultimately i was unsuccessful in doing so, despite using revert, and a bunch of other tools.
Gregg Lind
@Gregg, sorry to read that. You could document what you have ultimately done in an answer of your own in this page.
VonC