Re: how do I write a shell script to batch rename files in a directory?

2008-08-29 Thread ONYTZ
"\r" is a > carriage return character. The ls program is converting the > non-printable character into a ? for display. -- View this message in context: http://www.nabble.com/how-do-I-write-a-shell-script-to-batch-rename-files-in-a-directory--tp19227042p19228305.html Sent from the Gnu - Bash mailing list archive at Nabble.com.

Re: how do I write a shell script to batch rename files in a directory?

2008-08-29 Thread Chris F.A. Johnson
On 2008-08-29, Bob Proulx wrote: > Tony Zanella wrote: >> I have a directory listing of files like: >> img.bc03.547.1.gif? >> I need to trim the last character off for each file in the dir. >> I know I can use: >> mv img.bc03.547.1.gif? img.bc03.547.1.gif >> to rename each by hand, but I want to do

Re: how do I write a shell script to batch rename files in a directory?

2008-08-29 Thread Bob Proulx
Tony Zanella wrote: > I have a directory listing of files like: > img.bc03.547.1.gif? > I need to trim the last character off for each file in the dir. > I know I can use: > mv img.bc03.547.1.gif? img.bc03.547.1.gif > to rename each by hand, but I want to do this as a batch. > I know it would start

how do I write a shell script to batch rename files in a directory?

2008-08-29 Thread Tony Zanella
Hello all, I have a directory listing of files like: img.bc03.547.1.gif? I need to trim the last character off for each file in the dir. I know I can use: mv img.bc03.547.1.gif? img.bc03.547.1.gif to rename each by hand, but I want to do this as a batch. I know it would start with: for files in *;