Omaha #3690 added tool to remove empty localization dirs

Change-Id: Id5ec16147d9f159fa17645da79d29d1f5cbaa701

Former-commit-id: a69773742e571a334ef1fd000ff8311805f9c737
This commit is contained in:
Brian Clements 2014-10-06 15:01:18 -05:00
parent 28545083c5
commit f39ffcc63f

View file

@ -0,0 +1,20 @@
#!/bin/bash
# Omaha #3690: Finds empty localization directories and deletes them with the
# '-d' flag. This can improve performance in some areas of the system.
if [[ $1 == '-d' ]]
then
echo "Delete all directory trees that don't contain regular files? [y/n]"
read answer
if [[ $answer == 'y' || $answer == 'Y' ]]
then
DEL_OPTS='-delete -print'
echo "Deleting the following directories"
else
echo "Aborting"
exit 1
fi
fi
find /awips2/edex/data/utility -type d -empty $DEL_OPTS