Useful Svn Commands

How to ignore a folder in svn?

Here’s how you can have svn ignore the whole cache folder:

svn propset svn:ignore "*" cache/

How to add multiples files in one command?

svn st | grep "^?" | awk '{ print $2}' | while read f; do svn add "$f"; done

How to go back to earlier revision number?  or, How to undo svn commit?  This command will return the code to revision 10.

svn merge -rHEAD:10

If you want to set some ignore files at each directory, use

svn propedit svn:ignore <directory>

which opens your text editor.  Put the ignore pattern, for example:

*.png
*.eps

How to remove svn folders

Leave a comment