@Override
            public FileVisitResult preVisitDirectory(Path dir, BasicFileAttributes attrs) {

                // Ignore any .git subtree
                if (keepGitStuff && dir.endsWith(GIT_REPO_DIRNAME)) {
                    return FileVisitResult.SKIP_SUBTREE;
                } else {
                    return FileVisitResult.CONTINUE;
                }
            }
Deletes a file tree recursively. Does not delete any .git
directories nor any README.md.

@param root         Delete everything under this directory. Must not be null.
@param keepGitStuff If true then keep Git key files - .git/, README.md.
                    If false then delete everything.
@throws IOException if something goes wrong.
stroom-gitrepo/stroom-gitrepo-impl/src/main/java/stroom/gitrepo/impl/GitRepoStorageService.java