I want to be able to move $oldfile to my backup folder and add the date to the file name. So I tried this...
mv $oldfile /home/u0146121/backupfiles/$oldfile_$(date +%F-%T)
This just gives me this output filename. (no orignal filename)
Then I realized the potential problem for the above method. I have a while read loop that reads through a text file of path names for other files I wanted to compare. So for example, $oldfile is actually =
$ cat oldfiles.txt /home/u0146121/OldLogFiles/file2.txt
So... I want to be able to move the file2.txt and just keep the file2.txt name and add the date to it as well.