Search code examples
winscp

Is there a way to delete all directories with the same name?


Long story short, I am trying to delete all .svn folders within my site.

I have tried to use a file mask: */.svn/*

Search in: /data/www/content/

But it's returning files named entries. It shows me all the directories the entries file is showing in which is helpful, but then I need to go to that directory and delete them one at a time.


Solution

  • The small help popup says that masks ending in / will find folders, so I tried .svn/ and it does find that in the current folder. But it does not search recursively in sub folders.

    Since you are using WinSCP you probably have Bash or SSH access too, you could try one of the scripts mentioned in this Stackoverflow question: How to remove all .svn directories from my application directories