Back in 2017 when I built my very first WordPress plugin I had trouble uploading it to WordPress.org because I’ve never used SVN before. As a Git guy I’ve never worked with SVN before and at the time I was searching all over the web for some Git to SVN command reference.
I’m sharing this now mostly for me, but also in hope that someone else might find this reference useful also. 🙂
Description | GIT Command | SVN Command |
---|---|---|
Copy a repository | git clone | svn checkout |
Record changes to file history | git commit | svn commit |
View commit details | git show | svn cat |
Confirm status | git status | svn status |
Check differences | git diff | svn diff |
Check log | git log | svn log |
Addition | git add | svn add |
Move | git mv | svn mv |
Delete | git rm | svn rm |
Cancel change | git reset | svn revert |
Make a branch | git branch | svn copy |
Switch branch | git checkout | svn switch |
Merge | git merge | svn merge |
Update | git pull | svn update |
Update | git fetch | svn update |
It is reflected on the remote | git push | svn commit |
Ignore file list | .gitignore | .svnignore |