PDA

View Full Version : renaming a file


16-May-2004, 12:38 AM
I am trying to rename a single file in a script I am using. Could I get an example of how I should do that?
Thanks

Chris
17-May-2004, 01:13 PM
The rename command operates on the currently selected files, so first, select the files using something like:
select lt.newer

and then the rename command, using
rename <newname>
or
rename regexp <oldmask> <newmask>

If you're having problems with the selection mask, or with the rename masks, please post (or email to support) more information about the file you're trying to select and the names of the other files in the directory.

newb
25-May-2004, 06:44 PM
The rename using regular ex doesent <- work. It only works
running it from the gui side. Just what I need, software scripting that is totally useless to me now.

log verbose
load Test1
select rt.all
rename regexpr (.+) aa_$1

Chris
26-May-2004, 08:32 AM
I did some testing and the expansion of $1 to (mask) is broken in scripts. Other regular expressions are still working. I will add it to our bug list to be fixed. Sorry for the difficulty.