From a7aecff143878aab47a28d75a53c32a94f86a05e Mon Sep 17 00:00:00 2001 From: Rudolf Polzer Date: Tue, 31 Jan 2012 21:54:18 +0100 Subject: [PATCH] detect broken clones and delete them --- all | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/all b/all index b451ac7d..6c9f306b 100755 --- a/all +++ b/all @@ -235,6 +235,12 @@ listrepos() $ECHO "$d" continue fi + # remove broken clones so they don't mess up stuff + if [ x"$d" != x"." ] && [ -d "$d" ] && ! [ -d "$d/.git" ]; then + msg "$d exists but has no .git subdir. Probably a broken clone. Deleting." + verbose rm -rf "$d" + continue + fi # if we have the dir, always keep it if [ -d "$d" ]; then msg "Repository $d enabled because it already exists" -- 2.39.2