threads / discuss / 19246

Problem with local branches and git svn rebase

Subject: Problem with local branches and git svn rebase

## tl;dr

2 messages between May 8, 2009 and May 8, 2009.

replies: 1people: 1as markdown or json

Dan Fairs· May 8, 2009, 08:57 UTC · lore
Hi,

I'm experiencing a problem with local branches and the git svn rebase command. I'm using git 1.5.5.1. Basically, I can no longer 'git svn rebase'.

I've been doing all my work on a local branch 'work' which I've been successfully using with a remote SVN repository successfully for weeks. I yesterday needed to do some disruptive work, so I committed everything on my 'work' branch, created a new branch 'onlinehacking', checked it out, did some work on that, and committed. I then tried to check out my original 'work' branch and run a git svn rebase to pull down my colleagues' work. Here's what happens:

bash-3.2$ git branch
   dan-bf-merge-lc
   master
* onlinehacking
   work
bash-3.2$ git status
# On branch onlinehacking
nothing to commit (working directory clean)
bash-3.2$ git checkout work
error: Entry 'online.cfg' not uptodate. Cannot merge.
bash-3.2$ git checkout -m work
Checking out files:   8% (169/2051)
   ... snip ...
Checking out files: 100% (2051/2051)
Checking out files: 100% (2051/2051), done.
M	online.cfg
M	products/online/Formulator/CREDITS.txt
    ... snip ...

M products/online/Formulator/www/StringField.gif M products/online/Formulator/www/TextAreaField.gif Switched to branch "work" bash-3.2$ git svn rebase Cannot rebase with uncommited changes: # On branch work nothing to commit (working directory clean) status: command returned error: 1

bash-3.2$ git status # On branch work nothing to commit (working directory clean) bash-3.2$ git diff bash-3.2$ git diff --cached bash-3.2$

I'm still pretty new to git, so I'm sure that I've done somthing stupid, not git. I tried adding the -m option to 'git checkout work' as advised by the git-checkout man page, but git diff doesn't show any changes afterwards.

What have I done wrong, and how can I pull latest changes from svn into my work branch?

Thanks, Dan -- Dan Fairs <dan.fairs@gmail.com> | http://www.fezconsulting.com/

Dan Fairs· May 8, 2009, 14:41 UTC · re: Dan Fairs · lore

Re: Problem with local branches and git svn rebase

> I'm experiencing a problem with local branches and the git svn  
> rebase command. I'm using git 1.5.5.1. Basically, I can no longer  
> 'git svn rebase'.

For the benefit of the archive, a git rebase --abort on the 'work' branch fixed the issue, despite giving a 'No rebase in progress?' message. Thanks to tvakah on #git.

Thanks Dan

-- Dan Fairs <dan.fairs@gmail.com> | http://www.fezconsulting.com/

← back to recent threads