How to recursively delete all SVN files using PowerShell

If you really do want to just delete the .svn directories, this could help:

gci c:\yourdirectory -include .svn -Recurse -Force | 
   Remove-Item -Recurse -Force

Edit:
Added -Force param to gci to list hidden directories and shortened the code.

Keith is right that it you need to avoid deleting files with .svn extension, you should filter the items using ?.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)