bash command for each file in a folder

Posted by Robert on Ask Ubuntu See other posts from Ask Ubuntu or by Robert
Published on 2013-07-02T09:12:34Z Indexed on 2013/07/02 11:15 UTC
Read the original article Hit count: 685

Filed under:
|

I have a set of files on which I would like to apply the same command and the output should contain the same name as the processed file but with a different extension.

Currently I am doing rename /my/data/Andrew.doc to /my/data/Andrew.txt I would like to do this for all the .doc files from the /my/data/ folder and to preserve the name.

I tried several versions but I guess I have something wrong in the syntax as I an new to linux.

© Ask Ubuntu or respective owner

Related posts about command-line

Related posts about bash