]> gitweb.pimeys.fr Git - scripts-20-100.git/commitdiff
[watch_subscriptions] On s'assure que ce sont bien des dossiers mail qu'on considère
authorVincent Le Gallic <legallic@crans.org>
Wed, 4 Jan 2017 10:33:07 +0000 (11:33 +0100)
committerVincent Le Gallic <legallic@crans.org>
Wed, 4 Jan 2017 10:33:31 +0000 (11:33 +0100)
watch_subscriptions.sh

index 2f807f217e0a65de48e231ca2ba070d1e3dbd89b..28b8b28f8b7feb5cf7da66eddccfc19f167f08af 100755 (executable)
 MAILDIR=~/Mail
 
 cd $MAILDIR
-diff -u <(cat subscriptions | sort) <(find . -maxdepth 1 -mindepth 1 -type d | sort | sed 's/^...//')
+diff -u <(cat subscriptions | sort) <(find . -maxdepth 1 -mindepth 1 -type d -regex "\./\..*" | sort | sed 's/^...//')
 
 if [[ "$1" = *"apply"* ]]
 then
-    find . -maxdepth 1 -mindepth 1 -type d | sort | sed 's/^...//' > subscriptions
+    find . -maxdepth 1 -mindepth 1 -type d -regex "\./\..*" | sort | sed 's/^...//' > subscriptions
     echo
     echo "** APPLIED **"
 fi