On Thu, 5 Sep 2002 08:12:24 -0400, Kevin wrote:

>But obviously not the best or easiest way.  How is it I've used *nix for
>all these years and never heard of this command?

Don't know, maybe because everyone uses mv to rename? But this sure looks
easier than a for loop:

RENAME(1)           Linux Programmer's Manual           RENAME(1)

NAME
       rename - Rename files

SYNOPSIS
       rename from to file...

DESCRIPTION
       rename will rename the specified files by replacing the first
occurrence of from in
       their name by to.

       For example, given the files foo1, ..., foo9, foo10, ..., foo278, the
commands

              rename foo foo0 foo?
              rename foo foo0 foo??

       will turn them into foo001, ..., foo009, foo010, ..., foo278.

       And
              rename .htm .html *.htm

       will fix the extension of your html files.

SEE ALSO
       mv(1)

ps. I didn't know it existed either :-)



-- 
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]?subject=unsubscribe
https://listman.redhat.com/mailman/listinfo/redhat-list

Reply via email to