I'm using git-svn and I accidentally typed 'git svn rebase' on my feature branch, what are the ramifications?
Normally I type
git svn rebase on master, then I’ll type
git rebase master feature to update the feature branch. Is it safe to checkout master, do a
git svn rebase and skip the second step? I’m hoping that will be equivalent to what I normally do.
- git-svn and unfortunate svn pre-commit hooks
- Importing Subversion to GIT: problem with subpaths
- Merging of branch to trunk in SVN using Eclipse
- Migrating a large SVN repo to git
- Which style do you use for your commit messages? Technical or feature-based?
- Relocating SVN working copy following branch rename
I’m afraid I’ll cause issues once I
merge --ff-only from feature back into master and
2 Solutions collect form web for “I'm using git-svn and I accidentally typed 'git svn rebase' on my feature branch, what are the ramifications?”
You can use your reflog (
git log -g) to go back to where you were on the feature branch before the accidental
git svn rebase. The
git svn fetch component of the original command is fine so there’s no need to
git svn reset that. You can just go to your master branch and do the
git svn rebase as usual to clean things up.
As you say, there may not be any issue at all since you planed to do a rebase of that feature branch anyway.
I use a git svn repository mapped to a single svn branch. I did the same lately and I had no problems. I even did a dcommit directly from the feature git branch. In any case, you can always show the commits locally before dcommiting to make sure every thing is fine prior to further actions.