The Rename internal command can be used to:
Command Arguments:
Argument |
Type |
Possible values |
Description |
---|---|---|---|
(no argument) |
- |
- |
Displays the Rename dialog. The rename
operation will be performed on all selected files and folders. The dialog
will open in the last mode it was used in (either simple or advanced). |
ADVANCED |
/S |
(no value) |
Displays the Rename dialog in advanced
mode. |
AUTORENAME |
/S |
(no value) |
Automatically adds an incrementing number to the end of new filenames
if they clash with existing
files. |
BY |
/K/N |
<increment> |
Specifies the increment when renaming files with automatic numbering
(using the NUMBER option). If not specified the default
increment is 1. |
CASE |
/K |
upper |
Converts filenames to all-upper
case. |
|
|
lower |
Converts filenames to all-lower
case. |
|
|
firstword |
Capitalizes the first letter of the
filename. |
|
|
allwords |
Capitalizes the first letter of each word of the
filename. |
|
|
extupper |
Converts the filename extension to upper
case. |
|
|
extlower |
Converts the filename extension to lower
case. |
FILEINFO |
/S |
(no value) |
Enables file information fields when renaming files. This lets you use
file metadata (like MP3 artist tags, for example) to form the new names of
files. |
FINDREP |
/O |
(no value) |
Enable find-and-replace mode. The PATTERN argument
must be used to provide the string to find, and the TO
argument provides the string to replace it
with. |
|
|
ext |
Makes find-and-replace operate in the filename extension as well as in
the stem of the filename. |
FROM |
|
<filename> ... |
Renames the files specified on the command line, rather than those
selected in the source file display. This argument can accept filenames or
wildcard
patterns. Remember to enclose each filename in quotes if it contains
spaces. |
INLINE |
/O |
(no value) |
Activates inline
renaming on the item in the source file display that currently has
focus. |
|
|
all |
Automatically selects the entire filename for
editing. |
|
|
name |
Automatically selects the filename's stem (but not the extension).
Selects the whole name for a
folder. |
|
|
endstem |
Positions the cursor at the end of the filename's stem (before the
extension), but does not automatically select any part of the
name. |
|
|
ext |
Automatically selects the filename's extension. Selects the whole name
for a folder. |
|
|
home |
Positions the cursor at the beginning of the
filename. |
|
|
end |
Positions the cursor at the end of the
filename. |
|
|
single |
If more than one item is selected, the Rename dialog
will be displayed. Without this, inline rename will begin on the focused
item only. |
MATCHCASE |
/S |
(no value) |
Makes the rename operation case-sensitive. Patterns and search strings
must match the exact case of the
filename. |
NOMATCHNOFAIL |
/S |
(no value) |
Files which do not match the rename pattern are not 'failed'. This can
be useful with multi-line functions which need to do some optional
renaming before passing all of the files to additional commands. |
NUMBER |
/O |
(no value) |
Automatically number files. Selected files will be numbered in the
order they are presented in the file display, so you should make sure the
list is sorted as desired before using this command. The number 1 will be
assigned to the first selected file, and the number for each subsequent
file will be incremented by the value given for the BY
argument (or by 1 if BY is not
provided). |
|
|
<start> |
Number files starting with the specified number. Providing a value for
NUMBER also lets you zero-pad the assigned number. For example, the value
0010 means to start numbering at 10, and zero-pad to four
digits. The [#] marker can also be used to specify
zero-padding - [#5] would zero-pad to five
digits. |
PATTERN |
/K |
<pattern> |
Specifies a wildcard pattern that represents the old (original)
filename. This argument is used when performing a wildcard rename. The
Rename command supports a simple wildcard syntax where one or more
asterisks supplied for the PATTERN argument can be used
to copy parts of the original name to the new name. The
PATTERN argument is also used in conjunction with
REGEXP to provide the search pattern for a regular
expression rename, and in conjunction with FINDREP to
provide the search string for a find-and-replace rename. |
PRESET |
/K |
regexp |
Opens the Rename dialog in Regular Expression
mode. |
|
|
findrep |
Opens the Rename dialog in Find and Replace
mode. |
|
|
last |
Takes the settings from the last time the Rename
dialog was used and applies them to the currently selected files,
without opening the Rename dialog again. Similar to opening the dialog,
selecting Last Rename from the list of presets and clicking
OK. |
|
|
!list |
Displays a generated list of saved rename presets (acts as a dynamic button). Selecting
a preset from the list will apply that rename operation to the currently
selected files and folders. |
|
|
<preset> |
Applies the named saved rename preset to all currently selected files
and folders. Rename presets are created through the Advanced Rename
dialog. |
RECURSE |
/S |
(no value) |
The rename operation will operate recursively on all files inside
selected sub-folders. |
REGEXP |
/S |
(no value) |
Enables regular expression mode. The search pattern must be provided
with the PATTERN argument, and the replace pattern with
the TO
argument. |
RENAMEMATCHING |
/S |
(no value) |
Keeps files with the same stem and different exensions together when
renumbering. For example, IMGP1032.JPG and
IMGP1032.WAV when renamed would be given the same
number. |
SHOWPREVIEW |
/O |
(no value) |
Displays the preview panel when the Advanced Rename dialog
opens. |
|
|
no |
Does not display the preview
panel. |
SIMPLE |
/S |
(no value) |
Displays the Rename dialog in simple
mode. |
TO |
/O |
<new name> |
Specifies the new name of the file to rename. This argument is also
used to specify the 'to' pattern when renaming using wildcards or regular
expression, and the 'replace' string when renaming in find-and-replace
mode. This argument can also be provided without a value when doing a
find-and-replace rename - in that case, the search string would be
replaced with nothing. |
TYPE |
/K |
files |
Force the rename to only operate on files - any selected folders will
be ignored. |
|
|
dirs |
Force the rename to only operate on
folders. |