From Git SCM Wiki
Revision as of 11:22, 18 December 2012 by ThurnerRupert (Talk | contribs)

Jump to: navigation, search

This tutorial collects information for users of git as svn client, using git-svn. Please consider reading GitSvnCrashCourse, and the git-svn cheat sheet.


Checkout, log

git svn clone -r 400:HEAD folder # choose a recent commit
git log -5


Commit to local Git

Git automatically tracks contents and therefor automatically detects renames.

git add --all
git commit -m "whatebber"

Commit to remote SVN

To see what is going to be committed one can choose the following options.

gitk git-svn..
git log remotes/git-svn.. --oneline
git svn dcommit --dry-run

To really commit

git svn dcommit

Undo Changes

Undo, backout, or revert changes is done with standard git commands.

Things already committed to svn can be reverted:

git revert <hash>
git svn dcommit

Things in the working copy can be reset (reverted) to what is checked in:

git reset --hard

Some links

Personal tools