]> gitweb.fluxo.info Git - simplepkg.git/commitdiff
fix
authorrhatto <rhatto@04377dda-e619-0410-9926-eae83683ac58>
Fri, 28 Nov 2008 03:50:05 +0000 (03:50 +0000)
committerrhatto <rhatto@04377dda-e619-0410-9926-eae83683ac58>
Fri, 28 Nov 2008 03:50:05 +0000 (03:50 +0000)
git-svn-id: svn+slack://slack.fluxo.info/var/svn/simplepkg@586 04377dda-e619-0410-9926-eae83683ac58

trunk/lib/common.sh

index c7d0a76e4ff8a055147a1e4eae2d176080813021..35b2de799b36e8f4d46dd185833e0c6ab35ad0d4 100644 (file)
@@ -681,10 +681,12 @@ function svn_remove_empty_folders {
 
   main_folder="$1"
   search="`find $main_folder -type d | grep -v '/.svn' | sed '1d'`"
-  results="`echo $search | wc -w`"
+  results="`echo "$search" | wc -l`"
 
   if [ "$results" -eq "0" ]; then
-    svn_del $folder
+    if [ "`find $main_folder -not -type d | wc -l`" -eq "0" ]; then
+      svn_del $folder
+    fi
   else
     for folder in $search; do
       svn_remove_empty_folders $folder