Last Updated: February 25, 2016
·
1.33K
· rxc178

Migrating from SVN to Git

Here are some tips to make things go easily:

1) svn:ignore to .gitignore
svn propget -R svn:ignore .
Write the files printed by this command into a .gitignore file in the root of your project.

2) svn:externals to git submodule
svn propget -R svn:externals .
Switch these into a submodule in your git repo or just add the files to your project.

3) .gitkeep for empty directories
find . -type d -empty && touch /path/to/empty/dir/.gitkeep
Git doesn't like unnecessary baggage, so use .gitkeep to keep those things around.

4) Credits
svn log | grep -E 'r[0-9]+ ' | cut -d\ -f3 | sort | uniq
Make sure your team gets their share of the glory!

After alls said and done, you are ready to go with Git.
Welcome to the stress-free side of version control!