Hi,
Anybody help me to write a Shell Script
Get the latest file from the file list based on created and then move to the target directory.
Tried with the following script: got error.
A=$(ls -1dt $(find "cveit/local_ftp/reflash-parts" -type f -daystart -mtime -$dateoffset) | head -n1)
#if [ -n "$A" ] cp -u "$A" "$cveit/local_ftp/test/$(basename $A)"
got error invalid argument `-' to `-mtime'
Please help me to solve this.