a guest Aug 12th, 2017 46 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
- DIR="$( cd "$( dirname "$0" )" && pwd )"
- DATETIME="$(date +%Y-%m-%d.%H_%M_%S)"
- SUBDIRS="errors reports tempreports logs"
- for i in $SUBDIRS; do
- find $DIRPATH/$i -type f -mtime +62 | tee $LOGFILE | xargs tar -cz -f $ARCHI +++VEPATH/IMIQ-AdWords-Viewer_$i-$DATETIME.tar.gz
- while read line
- echo rm -f $line
- done < $LOGFILE
- rm -f $LOGFILE
RAW Paste Data