I want to rename all files ( could be also one file ) under dir directory so each file under dir will added with the name “old_” before each file
Remark – I can do the rename with loop and mv each file to the new file name But I prefer to do that with one command – is it possible?
when we need to rename one file is very simple
mv dir/file dir/old_file
but how to do the same when we have 100 files?
example
under dir I have
file1
file2
file3
what I want is
old_file1
old_file2
old_file3
OR
dse.txt
uytee.txt
drjf4.txt
convert to
old_dse.txt
old_uytee.txt
old_drjf4.txt