The Copy internal command can be used to:
Command Arguments:
Argument |
Type |
Possible values |
Description |
---|---|---|---|
ADDTOARCHIVE |
/O |
(no value) |
Displays the Add to Archive dialog,
to create an archive from the selected files. The dialog will default to
creating a Zip file. |
|
|
<archive format> |
Displays the Add to Archive dialog
with the archive type set to the specified format (given as the file
extension of the desired
format). |
|
|
fullpaths |
When creating Zip archives, this turns on the Save full file
paths option by default. |
|
|
nofullpaths |
When creating Zip archives, this disables the Save full file
paths option. |
|
|
split:<size> |
When creating Zip archives, this sets the default value for the
Split archive option. |
|
|
nosplit |
When creating Zip archives, this disables the Split archive
option. |
ARCHIVE |
/O |
(no value) |
Adds all selected files and folders to a Zip file named after the first
selected item. Note that if only a single folder is selected, the items
within that folder are added rather than the folder itself - this
prevents you from ending up with a Zip file containing an unnecessary
sub-folder. |
|
|
<archive format> |
Adds all selected files and folders to an archive of the specified
format. |
|
|
single |
Each selected item will be added to its own archive, rather than all
items being added to the one
archive. |
|
|
keepfolder |
Modifies the behaviour when only a single folder is selected - instead
of the items within the folder being added, the folder itself will be
added to the archive. |
AS |
/O |
(no value) |
When copying or moving files, you will be prompted to enter a new name
for each file. |
|
|
<new name> |
Specifies the new name or wildcard pattern for the copied
or moved files. |
BUFSIZE |
/K/N |
<size in bytes> |
Overrides the copy_buffer_size setting on the Miscellaneous / Advanced page in Preferences. The buffer size is specified in bytes, if no units are specified, and you can also use KB, MB and GB to specify larger sizes. This buffer is in addition to any buffering provided by the filesystem,
hardware, and so on; it is not connected to the non-buffered IO mode
controlled by the NONBUFIO argument and
copy_nonbufferio_threshold Preferences option.
|
BURNCD |
/S |
(no value) |
Invokes the system CD Burning Wizard, which initiates burning of any
files you have previously copied to the CD staging
area. |
CLEARREADONLY |
/K |
yes |
Clear the read-only flag when copying files from a CD (overrides the
Clear read-only flag when copying from CDs option on the
File
Operations / Copy Attributes Preferences
page). |
|
|
no |
Do not clear the read-only flag when copying files from a
CD. |
COLLLIST |
/S |
(no value) |
Displays a dynamically generated list of file collections - you can add selected
files and folders to a file collection simply by selecting it from this
list. Acts as a dynamic button. Most useful when used
in a drop-down menu or on a context
menu. |
COPYATTR |
/K |
yes |
Preserves file attributes when copying files or folders (overrides the
Preserve the attributes of copied files option on the File Operations
/ Copy Attributes Preferences
page). |
|
|
no |
Do not preserve file attributes (the newly copied file will have the
default file attributes for a newly created
file). |
COPYCREATIONTIME |
/K |
yes |
Preserve the creation time of copied files and
folders. |
|
|
no |
Do not preserve the creation time of copied files and folders. (The
current time will be used
instead.) |
COPYDESC |
/K |
yes |
Preserves file descriptions when copying files or folders (overrides
the Preserve the descriptions of copied files option
on the File
Operations / Copy Attributes Preferences
page). |
|
|
no |
Do not preserve file
descriptions. |
COPYDIRTIMES |
/K |
yes |
Preserves the created, modified and accessed times of copied
folders. |
|
|
no |
Prevents preservation of the created, modified and accessed times of
copied folders. |
COPYFILETIMES |
/K |
yes |
Preserves the created, modified and accessed times of copied
files. |
|
|
no |
Prevents preservation of the created, modified and accessed times of
copied files. |
COPYOWNER |
/K |
local |
Copy file owner information when the copy takes place between local
drives only (overrides the Copy owner option on the File Operations
/ Copy Attributes Preferences page). Note that under Vista
and above, setting the file owner requires elevation and so may produce a
UAC prompt. |
|
|
all |
Copy file owner information for all drives, not just local
ones. |
|
|
no |
Do not copy file owner
information. |
COPYPROPERTIES |
/K |
yes |
Copy NTFS properties/metadata when copying files and folders (overrides
the Copy metadata option on the File Operations / Copy
Attributes Preferences
page). |
|
|
no |
Do not copy metadata when copying
files. |
COPYSECURITY |
/K |
yes |
Copy security permissions when copying files between NTFS drives
(overrides the Copy security permissions option on the File Operations
/ Copy Attributes Preferences
page). |
|
|
no |
Do not copy security permissions. Newly copied files will inherit the
default security permissions of the destination
folder. |
COPYTOCOLL |
/K |
member |
When copying (adding) folders to a file collection, add them as members of
the collection (overrides the When copying folders to a
Collection option on the File Operations / Copy
Options Preferences
page). |
|
|
sub |
Copy folders to collections as sub-collections (the contents of the
folder will be added as member items to the newly created
sub-collection). |
|
|
ask |
Ask how to copy folders to
collections. |
CREATEFOLDER |
/O |
(no value) |
Prompts for the name of a new folder and copies the selected files and
folders into that folder. |
|
|
<folder name> |
Creates a new folder with the specified name and copies selected items
into that folder. You can specify an absolute path, or just a name - if
only a name is provided the folder is created in the destination (or
source if the HERE argument is also specified). You can
also use the external control codes to (for
example) automatically create a folder based on the current
date. When archiving files, this specifies the name of the archive to create
or update. (If you don't specify an archive name it will default to the
name of the first selected file, without its extension, or the name of the
current folder if no file selection is used.). The example below adds the
selected files to an archive called "Cat Photos.zip" below the current
folder: |
DUPLICATE |
/S |
(no value) |
Create duplicates of the selected items in the same folder. You will be
prompted to enter new names (or a wildcard pattern) for the
duplicated files. |
EXTRACT |
/O |
(no value) |
Extracts the contents of selected archives to the destination folder.
You can also use this with folders to copy their contents without copying
the folder itself. |
|
|
sub |
Creates a sub-folder in the destination named after the archive, and
extracts the archive contents to that
folder. |
|
|
checkout |
Extracts the contents of an archive to a temporary folder and
automatically opens that folder in a new Lister. You can use this to
"check out" the files in an archive before you decide if and where you
want to extract them to. |
FILE |
/M |
<filename> ... |
Specifies the name of the file or files to copy. If you don't provide
this argument the command operates on all selected items in the source
Lister. This is the default argument for the Copy command
- you don't need to specify the FILE keyword. |
FILTER |
/O |
(no value) |
Copies with filtering enabled (without having to activate the copy filter in the
Lister first). Opus will prompt you to define the
filter. |
|
|
<filter> |
Copies using the specified filter. This must have previously been
created from the File
Operations / Filters page in Preferences. You can also
directly specify a simple wildcard
pattern |
|
|
shift |
Copies with filtering enabled if the Shift key is held
down. Opus will prompt you to define the
filter. |
|
|
alt |
Copies with filtering enabled if the Alt key is held down.
|
|
|
ctrl |
Copies with filtering enabled if the Ctrl key is held
down. |
FLATVIEWCOPY |
/K |
single |
When copying items in different directories from a flat view file display, the files will all be
copied to the same target directory. This overrides the When
copying in Flat View mode option on the File Operations / Copy
Options Preferences
page. |
|
|
recreate |
Recreates the source folder structure when copying items in different
directories out of a flat
view file display. |
|
|
ask |
Opus will ask you what to do when copying items out of a flat view file
display. |
FORCE |
/S |
(no value) |
Automatically replace existing files without prompting. In-use files
that cannot be replaced will be automatically scheduled for replacement
next reboot. |
HERE |
/S |
(no value) |
Use the source folder as the destination folder (for example, archives
can be extracted to the same folder instead of the
destination). |
INCLUDEINLIBRARY |
/O |
(no value) |
Displays a dynamically generated list of libraries - you can include a selected
folder in a library simply by selecting it from this list. Acts as a
dynamic
button. Most useful when used in a drop-down menu or on a context menu. |
|
|
noread |
Prevents Opus from automatically navigating to the library when you
include a folder in it via the generated
list. |
|
|
$new |
Include selected folders in a new library. The new library will be
given the name of the first selected folder. Opus will automatically
navigate to the new library unless you include the
noread:
prefix. |
|
|
<library name> |
Include selected folders in the named library. Opus will automatically
navigate to the new library unless you include the
noread:
prefix. |
INSTALLFONT |
/S |
(no value) |
Installs new fonts in your system fonts folder. You do not need to
specify the destination folder when using this command - the fonts will be
copied to your fonts folder and registered automatically. This command has
no effect if non-font files are
selected. |
MAKELINK |
/O |
(no value) |
Creates shortcuts to all selected files and folders. Shortcuts do not
require NTFS. Shortcuts may point to things on different drives to
themselves. |
|
|
junction |
Creates junctions to all selected folders. Junctions are only supported
on NTFS drives. Junctions only work with folders (not with files).
Junctions may point to folders on different drives to
themselves. |
|
|
hardlink |
Creates hardlinks to all selected files. Hardlinks are only supported
on NTFS drives. Hardlinks only work with files (not folders). Hardlinks
cannot point to files on different drives to
themselves. |
|
|
softlink |
Creates softlinks to all selected files or folders, using absolute
paths. Softlinks require Windows Vista or above and are only supported on
NTFS drives. Softlinks work with both files and folders. Softlinks may
point to things on different drives to themselves. Creating softlinks
requires administrator access and will trigger a UAC prompt if
neccessary. |
|
|
relsoftlink |
Creates softlinks to any selected files or folders, using relative
paths where possible. A regular absolute link will be created if the
target can not be expressed relative to the link. (See
softlink for more information on
softlinks.) |
|
|
auto |
Automatically determines the most suitable type of link to create. On
Vista and above, it will usually create softlinks (for both files and
folders). On Windows XP, it will usually create junctions (for folders)
and hardlinks (for files). Shortcuts will be created instead in cases
where the desired link type is not applicable. For example, a shortcut
will be created if the drives are not NTFS or if a hardlink is desired but
the source and destination are on different
drives. |
|
|
autonosoft |
Does the same as auto except that it will not try to
create softlinks. It will usually create junctions (for folders) and
hardlinks (for files). Shortcuts will be created instead in cases where
the desired link type is not applicable. For example, a shortcut will be
created if the drives are not NTFS or for files where the source and
destination are on different
drives. |
MAKESFX |
/O |
(no value) |
Creates a self-extracting Zip file from
selected files and folders. If you select a .zip file then it will be
converted directly to self-extracting format; otherwise, the selected
items will be zipped first. |
MARKDESTARCHIVE |
/K |
yes |
Set the A attribute on newly copied files. You can use
this if have a backup solution that uses the A attribute
as an indication that a file has been backed up (overrides the
Mark copied files as archived option on the File Operations
/ Copy Attributes Preferences
page). |
|
|
no |
Do not set the A attribute on newly copied
files. |
MARKSOURCEARCHIVE |
/K |
yes |
Set the A attribute on the original files after they
have been copied (overrides the Mark original files as archived
after being copied option on the File Operations / Copy
Attributes Preferences
page). |
|
|
no |
Do not set the A attribute on the original files after
they are copied. |
MOVE |
/S |
(no value) |
Move selected files and folders to the destination (a.k.a.
cut-and-paste). If the destination folder is on the same drive as the
source then generally items can be moved through a simple rename
operation, which is very quick. When moving files between devices Opus
first copies them to the destination, and then deletes them from the
source. |
MOVEWHENSAME |
/S |
(no value) |
If the destination folder is on the same drive as the source then
selected items will be moved, otherwise they will be copied. This command
is used in the default drag-and-drop file type event (which mimics the
standard Explorer drag-and-drop behaviour where files are moved if you
drag them to a different folder on the same drive, and copied
otherwise). |
MOVEWITHSHIFT |
/S |
(no value) |
Selected items will be moved if the Shift key is held
down when the command is executed, otherwise they will be
copied. |
NONBUFIO |
/K |
yes |
Changes when the copy operation uses non-buffered mode, where the filesystem buffers provided by Windows are bypassed. For very large files, copying in non-buffered mode can increase the memory efficiency, copy speed and UI responsiveness. On the other hand, non-buffered mode may slow things down for smaller files or certain devices. In rare cases, non-buffered mode may not work at all (e.g. if you have a device which mis-reports its sector size). Use of this argument overrides the default file size threshold for non-buffered copies set via the copy_nonbufferio_thresholdAdvanced Preferences setting. You can specify "yes" or "no" to force non-buffered mode on or off for
all files, or specify the file size above which non-buffered mode should
be used. |
|
|
no |
Forces the copy operation to be buffered, even if the file being copied
exceeds the threshold size set via the
copy_nonbuffer_thresholdAdvanced Preferences
setting. |
|
|
<threshold size> |
The copy operation will be non-buffered if the file size exceeds the
specified size, and buffered otherwise. When specifying a size, units can
be KB, MB or GB. If no units are specified, MB is used by
default. |
PATTERN |
/K |
<old name pattern> |
Specifies the "old name" or "from" wildcard pattern for the copied
or moved files. Use this in conjunction with AS to
control wildcard renaming of copied or moved
files. |
QUEUE |
/O |
(no value) |
Enables automatic copy
queuing. File copies will be queued automatically if required (based
on the source and destination drives). This can override
the Automatically manage file copy queues option on
the File
Operations / Copy Options Preferences
page. |
|
|
<queue name> |
When you specify a queue name as the value for this argument, it
enables manual copy queuing when copying files. That is, with a name
specified, file copies will always be queued to the specified queue -
if no name is specified for the argument, copies will only be queued if
needed. The specified name will be shown in the progress dialog's title
bar. |
|
|
none |
Used to disable copy queuing - whether enabled in Preferences, or
otherwise enabled by the shift
keyword. |
|
|
shift |
Lets you specify two alternate parameters for the QUEUE
argument. The value specified before the shift
keyword is used if the Shift key is not held
down - the value after it is used if it is. For example, you could
configure a copy button to queue files to a specific queue if the
Shift key were held down, and to disable queuing
otherwise. |
|
|
quiet |
Specify the quiet keyword to suppress the prompt that
normally indicates a copy operation has been
queued. |
RENAMEWHENSAME |
/S |
(no value) |
If the source and destination are the same folder, the
newly copied file will be automatically renamed to avoid a
clash. |
SENDMAIL |
/O |
(no value) |
Send selected files as email attachments. Email settings must be
configured on the Internet / Email Preferences
page. |
|
|
<email address> |
Send selected files to the specified email recipient. This only works
if email sending is set to use the MAPI client on the
Internet / Email
Preferences page. |
SENDTO |
/K |
<send-to target> |
Send selected files to the specified "send to" target. This can be any
item that appears in the system Send To context menu, and lets
you perform the same action without actually displaying the context menu.
The value given for the target must be the name of the actual file in the
SendTo folder (to find the SendTo folder and see what's
in there, use the /sendtofolder
alias). |
TO |
/K |
<target path> |
Specify the target path for the command. By default Copy
functions that require a destination folder will use the current
destination file display or Lister - this argument allows you to override
that. Also see the HERE argument for a way to override the destination
path. You can use folder
aliases and
@ftp shortcuts, URL-style
paths for virtual
filesystems (collections, libraries, etc.) as well as standard file system
paths. Remember that if the specified path contains a space you must
enclose the whole path in
quotes. |
|
|
ask |
Normally if no destination path is specified, and there is no current
destination file display or Lister, Opus will prompt for a destination
path via a popup dialog. You can use the ask value to
force Opus to always prompt for a destination path, even if there already
is one. |
|
|
ask$ |
Force Opus to ask for a destination path. If you have a function that
combines multiple Copy commands, you can use
ask$ to make Opus only prompt for a destination path once
for the whole function, rather than prompting separately for each
Copy command. |
UNATTENDED |
/K |
yes |
Enables unattended
copy mode. In this mode, Opus will not display any confirmation
prompts or error dialogs - the copy will proceed until the end, and any
errors will be summarised upon completion. Use the other arguments like
WHENEXISTS to control what happens in certain
situations. |
|
|
no |
Disables unattended copy
mode. |
UPDATEALL |
/S |
(no value) |
Update files in the destination folder (a simple form of one-way
synchronization). Only files that either do not exist in the
destination, or do exist but are different from the source files, will be
copied - other files will be skipped. A file is defined as different if
either its timestamp or size has changed - the contents of the file are
not compared. |
UPDATEEXISTING |
/O |
(no value) |
Update existing files in the destination folder (a simple form of one-way
synchronization). Only files that already exist in the destination,
but are different from the source files, will be copied. Files that do not
already exist, as well as files that have not changed, will be skipped. A
file is defined as different if either its timestamp or size has
changed. |
|
|
size |
Update existing files whose size is different (ignore
timestamp). |
|
|
date |
Update existing files whose timestamp is different (ignore file
size). |
UPDATESECURITY |
/K |
yes |
Update security permissions and encryption settings for moved files, to
match the destination folder (overrides the Update
permissions/encryption to match the destination when moving files
option on the File Operations / Copy
Attributes Preferences page). For example, if a folder has
the E attribute set, files moved into that folder will be
automatically encrypted. |
|
|
no |
Do not update security permissions or encryption settings for moved
files (when files are moved via a rename, their existing permissions will
remain). |
UPDATETOLERANCE |
/K/N |
<tolerance seconds> |
Sets the maximum number of seconds an existing file's timestamp
can vary before it will be considered "different" by the UPDATEALL
or UPDATEEXISTING functions. The default is two
seconds (that is, a file will be considered different if its timestamp is
two or more seconds different to the source file). You can use this to
make allowances for daylight-savings time, or for file systems that don't
preserve file dates to a high enough
resolution. |
WHENEXISTS |
/K |
ask |
If a file that is being copied already exists in the destination, ask
what to do. This overrides the option Ask for confirmation
before overwriting existing files on the File Operations / Copy
Options page in
Preferences. |
|
|
skip |
If a file that is being copied already exists in the destination, skip
over it (leaving existing file
intact). |
|
|
replace |
Replace any existing files without
prompting. |
|
|
rename |
If a file with the same name already exists in the destination, the
newly copied file will be renamed automatically to avoid a
clash. |
|
|
renameold |
The old file (the one that already exists in the destination directory)
will be renamed before the new file is
copied. |
|
|
resume |
When copying to FTP sites, a previous incomplete file transfer will be
automatically resumed (only applies if the server supports FTP, and the
existing file is smaller than the one being
copied). |
|
|
merge |
Automatically merge the contents of an existing folder with that
of the folder being copied. This overrides the Ask for
confirmation before merging existing folders option on the File Operations /
Copy Options page in Preferences. You can use this value in
addition to another value to specify the 'when exists' behaviour for files
as well as folders. |
|
|
replacenewer |
Replace any existing files if the files being copied are newer. If the
timestamps are the same or older, the already-existing files will be
skipped. |