NEW RENAME UTILITY. PC-DOS STYLE by Miguel Vasquez CP/M's rename command (REN) is limited by its not being able to use wild cards ( ?'s and *'s ) in the file names. Recently , I ran into a program by George M. Gallen in either Dr. Dobb's or Microsystems (I cannot remember which one it was.) that allowed to change the extension of a group of files. After reading that program, it occurred to me that it would not take too much work to generalize it so that one could use wild cards anywhere in the file names. -At work, I have an IBM-PC under PC-DOS. In this operating system, the rename command (also called REN) does allow you to use wild cards in the file names. The program XREN.ASM (eXtended REName) is the result of these modifications. At first , I thought that although the program was nice I would not have too much use for it. But now that I have it, I find myself using it more and more . The syntax for using XREN mimics that of REN in PC-DOS : XREN [d:]OldFilename NewFilename where the drive specifier (d:) is optional and the file names can use wild cards (?'s and *'s) freely. examples: XREN *.DOC *.TXT will change all files with the DOC extension to having the TXT extension. The file name is not changed. XREN LIST*.* NLIST??.* will change all files that start with LIST to NLIST, will not change the extension and will keep the sixth and seventh characters in the original file name. There is one possible pitfall (to which PC- DOS's REN command is NOT immune) of this generality in file renaming rules: with the command: REN DAT*.* DATA?23.* if one of the original file names is like DAT.TMP, the strict application of the rules for the use of wild cards would produce a renamed name: DATA 23.TMP. YES, with a BLANK in the middle of the file name!. This is what PC-DOS does. Thus producing an inaccessible file. I have avoided this in XREN.ASM by adding one more rule: whenever a blank in the original name or extension is matched with a wild card (an ?) in the destination, the rest of the name or extension in the destination is filled with blanks. Thus, the previous example will produce: DATA.TMP as the renamed file. For those who are not very experienced in using the CP/M assembler, I describe what should be done to produce the executable XREN.COM file. 1.- Use the N option of Word-Star to type the (program) file XREN.ASM EXACTLY as shown. BEFORE saving your file, use the command ^QC to go to the end of the file, then save it. 2.- After returning to the CP/M prompt, put your CP/M system diskette in drive A: and the diskette with the file XREN.ASM in drive B:. 3.- Log drive B: Hit ^C and type B: 4.- Type: A:ASM XREN.BBB This will produce the following files in the B:drive XREN.HEX, XREN.PRN. On the screen you will see the following messages: CP/M ASSEMBLER - VER 2.0 03F7 002H USE FACTOR END OF ASSEMBLY Anything different from this will probably indicate an error in the file XREN.ASM. Check it carefully. 5.- Type: A:LOAD XREN You will see the messages: FIRST ADDRESS 0100 LAST ADDRESS 03CC BYTES READ 02CD RECORDS WRITTEN 06 All of this has produced the file XREN.COM in drive B: and you are done. Happy Renaming!.