Update UnmappedFolderCleaner.bash
This commit is contained in:
parent
142c646292
commit
8e389579d1
1 changed files with 6 additions and 6 deletions
|
@ -9,15 +9,15 @@ log () {
|
||||||
|
|
||||||
logfileSetup () {
|
logfileSetup () {
|
||||||
# auto-clean up log file to reduce space usage
|
# auto-clean up log file to reduce space usage
|
||||||
if [ -f "/config/logs/UnmappedFolderCleaner.txt" ]; then
|
if [ -f "/config/logs/$scriptName.txt" ]; then
|
||||||
find /config/logs -type f -name "UnmappedFolderCleaner.txt" -size +1024k -delete
|
find /config/logs -type f -name "$scriptName.txt" -size +1024k -delete
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -f "/config/logs/UnmappedFolderCleaner.txt" ]; then
|
if [ ! -f "/config/logs/$scriptName.txt" ]; then
|
||||||
touch "/config/logs/UnmappedFolderCleaner.txt"
|
touch "/config/logs/$scriptName.txt"
|
||||||
chmod 666 "/config/logs/UnmappedFolderCleaner.txt"
|
chmod 666 "/config/logs/$scriptName.txt"
|
||||||
fi
|
fi
|
||||||
exec &> >(tee -a "/config/logs/UnmappedFolderCleaner.txt")
|
exec &> >(tee -a "/config/logs/$scriptName.txt")
|
||||||
}
|
}
|
||||||
|
|
||||||
verifyConfig () {
|
verifyConfig () {
|
||||||
|
|
Loading…
Reference in a new issue