The Great Magnet. What a fool I was to defy him.

Entries categorized as ‘Bash’

Bash — svn rm on all matching files

July 2, 2008 · 2 Comments

I’ll need this in the future. I needed to do “svn rm” on each instance of something.pyc to remove it from the respository.

Found the solution online (sort of).

find -name "*.pyc" is the obvious part.

find -name "*.pyc" -exec svn rm {} \;

will erase all files ending in .pyc via svn rm.

Alternatively, you can also use something like

find -name "*.pyc" | xargs svn rm

kylefox below says that he needed to specify the path, which would be for current directory find . -name “*.pyc” -exec svn rm {} \;

Categories: Bash
Tagged: