
Rename-Them-All 1.061beta Linux Freeware Version
Copyright (C) 1999 Tomi Tiilikainen


RTA is a powerful rename program, if you have lots of files and
directories and you want to put them under your naming conventions.


COPYRIGHT
---------

Permission to use, copy, and distribute this software and its
documentation, in whole or in part, for any purpose (except as
detailed hereunder) is hereby granted without fee, provided that
the above copyright notice and this permission notice appear in
all copies of the software and related documentation. Notices of
copyright and/or attribution which appear in any file included in
this distribution must remain intact. You may not disassemble,
decompose, reverse engineer, or alter this file or any of the
other files in the package.

This software is provided as FREEWARE, and cannot be sold.  This
restriction does not apply to connect time charges, or flat rate
connection/download fees for electronic bulletin board services.
This software can not be bundled with any commercial package 
without express written permission from Tomi Tiilikainen.

Source code for this software is proprietary information of Tomi
Tiilikainen.

THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
IN NO EVENT SHALL TOMI TIILIKAINEN BE LIABLE FOR ANY SPECIAL,
INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY
DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY 
THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE
OR PERFORMANCE OF THIS SOFTWARE, EXCEPT TO THE EXTENT OF ANY
UNAVOIDABLE STATUTARY LIABILITY.


USAGE
-----

    1. Target   Include file(s)/dir(s)  Exclude file(s)/dir(s)
rta target_path target1 [...]           [-xcl: target_exclude1 [...]]

    2. Source                        3. Destination        4. Switches
    [-src: [src_string]:[src_index]] [dst_string]:dst_mode [-d][-s][-t][-p]
                                                  r|a|b|l|u

   RTA searches substrings (src_string) from file- or directory
   (specified by Target) names and specifies characters and/or strings
   (src_index) from the found substrings. The result is called Source.

   Then it executes operation to Source, operation is given by
   dst_mode. Depending on dst_mode RTA replaces Source with dst_string
   or adds dst_string to Source or makes lower- or upper-case transform
   to Source.

   All arguments except Target are case sensitive.
   Wildcards '*' and '?' can be used when choosing Target.
   Wildcard '?' can be used with src_string.

1. Target

   Target selects file(s)/dir(s) which will be renamed if src_string is
   found from them. File(s)/dir(s) are excluded from Target if they
   are given after "-xcl:" identifier.

   If the first character of the include/exclude file/dir (i.e. @xxx)
   is '@' and there is no match for the file/dir named "@xxx" then the
   include/exclude file(s)/dir(s) (newline separated) are read from
   the file named "xxx".

   If subdirs are processed (-s switch) include/exclude file(s)/dir(s)
   can be given with or without path. For example:

   1) rta foopath * -xcl: ./foofile foodir/foofile :u -s
        Only ./foofile and foodir/foofile are excluded.
        "./" refers to foopath (target_path) directory.

   2) rta foopath * -xcl: foofile :u -s
        All the files named foofile under foopath are excluded.

2. Source

   There is four ways to give Source.

   1) -src: src_string:
        All the substrings which match src_string are searched from
        Target.

   2) -src: s r c _ s t r i n g:src_index
            0 1 2 3 4 5 6 7 8 9=E
        You can refer to src_string characters by using src_index.
        src_index can be composed of ranges and/or indexes.
        For example: foobar:0,2-4,E
        At first "foobar" strings are searched from Target, then
        characters 'f' and 'r' and string "oba" are selected from
        them.
        Character 'E' in src_index refers to the last character of
        src_string.

   3) -src: :src_index
        Is same as 2), but src_index refers direct to the name of each
        target file/dir.

   4) No source argument.
        Is same as -src: :0-E

3. Destination

   dst_string is optional in dst_modes :r :a :b, if not given
   dst_string is empty string "".
   In dst_modes :u :l dst_string can't be given at all.

   [dst_string]:r
        Source is replaced with dst_string.

   [dst_string]:a
        dst_string is added after Source.

   [dst_string]:b
        dst_string is added before Source.

   :l
        Source is converted into lower-case letters.

   :u
        Source is converted into upper-case letters.

4. Switches

   -d   Directories. Target is dir(s), without -d Target is file(s).
   -s   Subdirectories. Process subdirectories also.
   -p   Pause. Pause before every rename operation.
   -t   Test. Do everything except actually rename Target.


You must disable shell's wildcard expansion to be able to use
wildcards '*' and '?' (problem exist only with -s switch). You can
disable it by adding backslash before every wildcard ('\*' '\?').

WARNING!
Be careful with -s switch or you soon have hard-drive full of funny
named files or directories. It is reasonable to use -t or -p switch to
be sure what will happen.

Check examples.txt for renaming examples.

Please send email, if you have any comments about this program.

29.5.1999  Tomi Tiilikainen  ttiilika@lpt.fi

PS. Sorry for the possible language errors, english is not my
mother language u know.
