How to rename a set of *.txt files to *.c
Anonymous
mv cant be used because it will try to find a file with name *.c. So need to use for loop kind of thing. for example: 1)for i in `find / -type f -name '*.txt' -print` do x=`cut -d'.' -f1` mv $i $x.c done 2) ls *.txt|sed -e 's/.*/mv & &/' -e 's/.txt/.c/2'|sh
Check out your Company Bowl for anonymous work chats.