To recursively remove all svn management files (.svn) from a working copy, simply navigate to the root directory of your working copy and execute the following command:
find . -name ".svn" -exec rm -rf {} \;
Another solution is to create an alias in your ~/...
TBWritten byThomas Bourdin1 min read
To recursively remove all svn management files (.svn) from a working copy, simply navigate to the root directory of your working copy and execute the following command:
find . -name ".svn" -exec rm -rf {} \;
Another solution is to create an alias in your ~/.bashrc and then execute the command when needed:
alias rmsvn='find . -name ".svn" -exec rm -rf {} \;'
Precautions before executing the order
This tutorial retains the command and the context of its publication. Before using it on a current repository, inspect the branch, the modified files, and the exact target:
git status --short
git log --oneline --decorate -5
Create a backup branch or tag when the operation rewrites history or deletes files. In particular, git reset --hard overwrites the changes in the working directory.