home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Dream 49
/
Amiga_Dream_49.iso
/
amiga
/
workbench
/
commodoties
/
case.readme
< prev
next >
Wrap
Text File
|
1998-02-11
|
8KB
|
196 lines
Short: Powerful prg to rename/manipul filenames
Author: parsec@aljan.com.au (Erik Spσre)
Uploader: parsec@aljan.com.au (Erik Spσre)
Version: 2.2
Type: util/cli
Requires: OS 2.04 or above
*****************************************************************************
** Case 2.2 - Filename Changer - by Erik Spσre (Parsec/Phuture 303) 980127 **
** Filematching routines by Anders Vedmar (Axehandle/PC303) **
*****************************************************************************
Very powerful program that lets you rename multiple files. Features:
* Recursive pattern matching (no pattern targets all files in current dir)
* More than 60 recognized extentions.
* ENV:Caseopts file, where you can, for instance, add more extentions.
* 5 Different lower/uppercase modes in many variants.
* 8 extention operations (like add/remove/swap suffix/prefix/extention)
* 11 string manipulation operations (like remove string, add head/tail)
* Can handle *all* letters, not only a-z.
* Direct or indirect renaming mode, won't crash on the ram-disk.
* 100 percent 68000 assembler (I hope, have only tried it on my 060)
* Freeware
* And more...
An example... Case -l -t -k -apmod Case -sp -w -ue
MOD.OCEAN_LOADER_FIXED ==> mod.ocean_loader_fixed ==> Ocean_Loader_Fixed.MOD
Mod.Green beret ==> mod.green_beret ==> Green_Beret.MOD
mod.CRYSTAL HAMMER ==> mod.crystal_hammer ==> Crystal_Hammer.MOD
DOC1 ==> mod.doc1 ==> Doc1.MOD
Hunters_moon ==> mod.hunters_moon ==> Hunters_Moon.MOD
MOD.SleepWalk ==> mod.sleepwalk ==> Sleepwalk.MOD
MOD.(((nebulos))) ==> mod.nebulos ==> Nebulos.MOD
mod.CREAM OF THE EARTH ==> mod.cream_of_the_earth ==> Cream_Of_The_Earth.MOD
MOD.telephone!!! ==> mod.telephone ==> Telephone.MOD
Here's a list of all the options...
The caseing options
-l All Lowercase
-u All Uppercase
-w Each new Word uppercase
-f First letter uppercase
-c Change cases
-i Ignore suffix and/or prefix when caseing
-I Don't Ignore suffix and/or prefix when caseing
The extention operations
-a Add specified prefix/suffix/extention
-r Remove [specified] prefix/suffix/extention
-C Change [given] pref/suff/ext to specified
-s Swap prefix and/or suffix
-E Ignore default extensions [only accept specified]
-e Only accept default extentions [and specified]
-L Set new prefix and/or suffix maxlength
-g Give priority to prefix or suffix
The string manipulation operations
-t Transform spaces to underlines
-T Transform underlines to spaces
-d Delete all the spaces [or only specified]
-D Delete specified strings
-C Change string 1 to string 2
-k Keep letters, digits, some more [and specified]
-K Keep A-Z, digits, some more [and specified]
-m Mutilate chars with ASCI values exceeding 128 to 45-127
-a Add head/tail string to filename
-r Remove head/tail string from filename
-v Vomit files to PC-format
The remaining options
-D Disable env:caseopts file
-q Be Quiet (only list errors)
-n Neglect the directories
-b Use a buffer when renaming (indirect)
-B Don't use a buffer when renaming (direct)
-S Simulate caseing, don't actually rename anything
ALL To recurse into subdirs.
Changes since version 2.0...
** Renamed almost all options, in a vain attempt to be more
consequent, and make the names easier to remember.
** Prefix options that default to operating on extentions, but
that can be made to operate on only prefixes/suffixes, now accept
e (for both) as well as the usual p (prefixes only) and s
(suffixes only)
** All specified extentions are now added to the list of
recognized extentions. So if you want to remove the suffix .bla,
you only need to write -rsbla, and don't worry about whether bla
is a recognized suffix or not.
** Any given extention will adjust the extention maxlenght, if
(and only if) it is exceeded.
** If a filepattern contains spaces, it now must have single or
double quotes surrounding it.
** The delete chars functions are no longer case-sensitive. If you
want to remove all ÷:s, -d÷ will remove ÷:s as well as ╓:s.
** It is now possible to specify characters to delete on several
places, without having the previous chars forgotten.
** If an extention operation is selected, but no extention was
modified, or even found, Case will now display a little reminder
that maybe this was because you wanted to process files with
alien extentions, and maybe you should try the -e option etc. This
is so you won't think Case is flawed, like even I myself has
thought several times! So easy to forget...
** Made an indirect mode to read all the filenames into a
buffer, and then rename from that. Added the options -b and -B
to select between direct and indirect mode.
** Added -ae, add specified extention.
** Added -r(h|t)<$>, remove head or tail string
** Added -C"<$>",<$> -- change string one to string two.
** Added -C<%>[<$>,]<$>, change extentions [from this] to that.
** Added -S, simulate caseing.
** Added a new caseing operation, -c, change all cases.
** Added -m, mutilate ASCII 128-255 into 45-127
** The -v (vomit) option now turns on -m, and it will no longer
remove the prefixes by default. You'll have to write -vp if you
want those removed as well.
** The caseing operations (-l, -u, -c, -w, -f) will now operate
on extentions only, if they are followed by p, s or e.
** A few minor bugs corrected
** More extentions are recognized...
qt, gz, pi
c++, cpp, arj, obj, env, mov, avi, jpg, tex, p61
tar, htm, man, mpg, mp3, bz2, tgz, lzh
jpeg, gzip, html
amiga, prefs
symmod
Changes since version 2.1...
** Above mentioned new extentions were actually only added to the doc.
I forgot to add them in the source. Apart from all those new
extentions, there's three more: xm, s3m and rexx.
** Corrected flaw in the argument parsing. Case wouldn't report a
syntax error when several source-names were entered. (This is not
yet allowed)
** When in recursive mode, if a directory-name got renamed by Case,
(so the characters actually changed, not only the cases) any
files in that directory would not be found. Solved this by
letting the pattern matching routine pass Case the directory names
when they were leaved, instead of when they were entered.
** Whenever a file in the search path could not be locked for some
reason, case would abort the whole operation with "can't find file
or path!" If in the default buffered mode, no files would ever be
renamed. Now, whenever the filematching routine cannot lock a file,
Case will look at the name to determine if the user wanted that
file to be renamed. (If, for instance, the user wanted to uppercase
all filenames, and this file already was uppercased, there would be
nothing to worry about.) If he didn't the file will simply be skipped.
If he did, the fail counter will be incremented and the message "can't
lock xxx because object is in use" will be displayed.
** The -C" option (change string 1 to string 2) was flawed.
case21 -C"bl",bl bla would result in renaming bla to bla. Also:
case21 -C"bl",bla bla would not rename bla to blaa, since Case thought
this had already been done.
Remember:
"This should be in every man's c-directory"
/Axehandle.