Hi All,
Am trying to write a script which does the archiving of *.txt files if it's one week old from the current date.
/TK/Project_ATT/Results/
File format :
-rw-r----- 1 root root 20562 Sep 11 10:24 UQ-CI01_FF_20130905_10H24M.txt
-rw-r----- 1 root root 20562 Sep 11 10:29 UQ-CI01_FF_20130906_10H29M.txt
-rw-r----- 1 root root 20562 Sep 11 10:26 UQ-CI01_FF_20130907_10H26M.txt
-rw-r----- 1 root root 20562 Sep 11 10:29 UQ-CI01_FF_20130908_10H29M.txt
-rw-r----- 1 root root 20562 Sep 11 10:29 UQ-CI01_FF_20130909_10H29M.txt
-rw-r----- 1 root root 20562 Sep 11 10:30 UQ-CI01_FF_20130910_10H30M.txt
-rw-r----- 1 root root 20596 Sep 11 10:34 UQ-CI01_FF_20130911_10H34M.txt
from the above *.txt, script should archive UQ-CI01_FF_20130905_10H24M.txt file (by taring the file) only since it's week old file from current date and putting into Archive directory.
/TK/Project_ATT/Archive/
-rw-r----- 1 root root 20562 Sep 11 10:24 UQ-CI01_FF_20130905_10H24M.tar.gz
Any help will be much apprecitated.
Many Thanks,
Optimus81