allan.simon
allan.simon

Reputation: 4326

Git SVN, Unable to determine upstream SVN information from working tree history after git rebase

We're doing a two way synchronization of one single branch "basic"

I've been able to git svn dcommit before

When I do (in order to do the git -> svn part , for svn -> git , git svn fetch works like a charm)

git checkout -b svntrunk trunk 
git rebase basic svntrunk
git svn dcommit 

the last command end with

Unable to determine upstream SVN information from working tree history 

If I do the rebase directly on basic I finish with basic being messed up with the svn version of the commit (when we've 'dcommit' before on top of the actual commits) which seems to tell me that's not the way to go

Am I missing a step ?

Upvotes: 3

Views: 2075

Answers (1)

Mykola Gurov
Mykola Gurov

Reputation: 8725

The second command in your sequence ( git rebase basic svntrunk ) detaches svn-based commits from the svn's trunk and rebases them on top of the git's basic branch. Use git svn info to check the context of svn branch you are operating at. I would expect that error already after the rebase step.

What you would probably want to do is rebase your changes on top of the latest svn commit. That could be git rebase svntrunk basic.

If you started your basic branch from trunk (you may check it again with the help of git svn info), then mere 'git checkout basic && git svn dcommit' might be enough as dcommit does rebase for you.

Upvotes: 2

Related Questions