git svn clone http://svn.example.org/svn/my-project my-project-git -T trunk -t tags -b branches
cd my-project-git
git svn fetch
If there are files you don’t want to commit, it may make sense to ignore them. If you use .gitignore
then you’ll have to avoid committing that file. Instead, add it to .git/info/exclude
Overall flow:
git checkout feature-branch
git checkout main
git svn rebase
git checkout feature-branch
git rebase main
git checkout main
git merge --squash feature-branch
git commit -m "Commit comment"
git svn dcommit
pushes those git commits up as svn commitsgist svn rebase
git format-patch main --stdout > my-patch-file-name.patch