renaming all the files in a folder

 IF we want to rename all the files with a part of the file we can do something following:

for file in $(ls); do nn=$(echo $file | awk -F'_' '{print($2)}'); mv $file $nn; done

Comments

Popular posts from this blog

Citrix receiver on linux version LUbuntu

Installing 64 bit adobe in firefox