Usuwanie plików .svn z katalogu projektu

Notatnik programisty zawsze pod ręką!

Usuwanie plików .svn z katalogu projektu

Version control systems are hugely important when it comes to development of all kinds.  I’m a huge fan of git but sometimes I’m required to use SVN.  Unfortunately I tend to forget to remove .svn folders when I copy and paste from a directory structure template.  This, of course, leads to me overwriting files and results in mass confusion.  I recently stumbled upan awesome command line script which recursively removes .svn directories from parent directories.

find . -type d -name .svn -exec rm -rf {} \;

The script starts within the current directory, so be sure you navigate to the directory you want to start searching from first. This script would work on any search type; simply replace „.svn” with the search of your choosing but be careful:  if your search term is too general, you may end up deleting a bunch of stuff you don’t want to!


Dodaj komentarz

Twój adres email nie zostanie opublikowany. Pola, których wypełnienie jest wymagane, są oznaczone symbolem *