server/clear_cache.sh

20 lines
319 B
Bash
Raw Normal View History

2014-11-20 20:03:35 +00:00
#!/bin/bash
2013-12-14 05:11:14 +00:00
# This script deletes Onyx framework cache
2013-12-14 05:11:14 +00:00
cd `dirname "$0"`
2015-01-13 07:13:49 +00:00
. ./config.sh
2013-12-14 05:11:14 +00:00
for n in "$@"
do
MD5=`echo -n $n | md5sum | cut -d " " -f 1`
if [ -f "onyx/cache/$MD5.cache.php" ]
then
rm -f "onyx/cache/$MD5.cache.php"
echo "--- $n deleted"
else
echo "/!\\ $n not found ($MD5)"
fi
done