Magical SVN Remove

Posted by hardwarehank, Sun Aug 06 15:37:52 UTC 2006

Have you ever wanted to batch remove some Subversion files? Try this on for size:


svn rm `svn stat | grep ! | sed -e 's/^\!\s\+//;s/$/ /' | tr -d '\n'`

That will remove all the entries from svn stat that start with !. Very handy. Took a few minutes to write (sed wouldn’t get rid of my newline, so I used *tr* …), but it’s worth it.

Tags:

Comments

Have your say

A name is required. You may use Markdown in your comments.