Hello all, probably a really quick and easy anwser to this, but didn't really know what to search for or how to word it. So my question is ..
When I use the cp or mv command to copy/move files is there a way for me to have the destination file assume the same name of the source file, however add an additional suffix. For example
#>cp /tmp/testfileReallyReallyLongNameDoNotWantToHaveToType.log /tmp/logs/
this will copy test.log into the /tmp/logs/ directory, resulting in the file create /tmp/logs/test/log
now what if I wanted this...
#>cp /tmp/testfileReallyReallyLongNameDoNotWantToHaveToType.log /tmp/logs/testfileReallyReallyLongNameDoNotWantToHaveToType.log.bak
Do I have to type the destination file out manually everytime? or is there a quick way for the cp or mv command to assume the source file name and add the .bak