home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.texkom.ru
/
ftp.texkom.ru.tar
/
ftp.texkom.ru
/
Plugins.zip
/
Plugins
/
FARCmds
/
FARCmdsEng.hlf
< prev
next >
Wrap
Text File
|
2003-02-24
|
14KB
|
415 lines
.Language=English,English (English)
.PluginContents=FAR Commands
@Contents
$^#FAR Commands#
The FAR Commands Plugin (FARCmds) provides additional features that may
be used in the User Menu, file associations or the command line.
~Syntax~@Syntax@
~"Same Folder" Command~@TheSameFolder@
~Configuring FAR Commands~@Config@
@Syntax
$^#FARCmds Syntax
#Command Line Syntax#
<prefix>:<command>[<options>] <object>
or
<command>:[<options>] <object>
where
#<prefix># - always #far#
#<command># - one of the following:
~view~@View@ - Viewer
~edit~@Edit@ - Editor
~goto~@Goto@ - Jump to a file or folder
~clip~@Clip@ - Put data in the clipboard
~whereis~@WhereIs@ - Locate and jump to an object
~macro~@Macro@ - Macros
~ln~@Ln@ - create of links
~run~@Run@ - execute commands
#<options># - only for the #edit# command; one of the following:
#[line]#
#[line,column]#
The square brackets are mandatory.
#<object># - one of the following:
#filename# - name of the file to be viewed,
edited or jumped to.
#path# - file or directory path to jump to.
#<command# - ~intercept output~@Direction@ of operation
system command.
Symbol #<# is obligatory.
#<<command# - ~intercept output~@Direction@ of operation
system command.
Symbol #<<# is obligatory.
Note:
A command can be executed in a directory different from the
current directory if the path is specified before an
operating system command enclosed in #'|'# characters.
Example: '#edit:<|%TEMP%|dir#'.
See also: ~Contents~@Contents@ | ~Output Redirection~@Direction@ | ~Notes~@Remark@
@Clip
$^#The Clip command#
The #clip# command puts data into the Windows clipboard.
The data can be the contents of a file or the output of a program.
The clipboard will contain all the data up to the character with the
code #0x00# (1 megabyte at most).
#far:clip filename#
or
#clip:filename#
See also: ~Output Redirection~@Direction@ | ~Notes~@Remark@
@Run
$ #The Run command#
The #run# command executes an operating system #command# redirecting
its output to the specified file #"filename"#. Output can also be displayed
on the screen or hidden from the user using ~Output Redirection~@Direction@ modifiers.
#far:run filename<command#
#run:filename<command#
See also: ~Output Redirection~@Direction@ | ~Remarks~@Remark@
@View
$^#The View command#
The #view# command opens the file "#filename#" in the FAR
built-in ~viewer~@:Viewer@:
#far:view filename#
or
#view:filename#
See also: ~Output Redirection~@Direction@ | ~Notes~@Remark@
@Edit
$^#The Edit command#
The #edit# command opens the file "#filename#" for editing
in the FAR built-in ~editor~@:Editor@. The command may be invoked in three ways:
1. Open a file for editing
#far:edit filename#
or
#edit:filename#
2. Open a file for editing and go to the line "#<line>#"
#far:edit[<line>] filename#
or
#edit:[<line>] filename#
3. Open a file for editing and go to the given position
#far:edit[<line>,<column>] filename
or
#edit:[<line>,<column>] filename#
If the file "#filename#" does not exist, it will be created.
If the newly created file is not changed before leaving the editor, it will
be deleted (same behaviour as Shift-F4).
If the filename contains square brackets (for example: "[1].txt"), then for
the correct opening of the file in the editor you must provide at least one delimiter
(e.g. a space) before the filename, or enclose it in quotation marks:
edit: [1].txt
edit:"[1].txt"
See also: ~Output Redirection~@Direction@ | ~Notes~@Remark@
@Goto
$^#The Goto command#
The #goto# command jumps to a file or a folder. The path can be
specified in two ways:
1. Directly as a parameter of the command
#far:goto path#
or
#goto:path#
2. The path is taken from the file "#filename#"
#far:goto <filename#
or
#goto: <filename#
If the parameter "#path#" specifies a folder and is terminated with
a backslash ('#\#'), the plugin jumps to the specified folder. If the
path to the folder is not terminated with a backslash, the cursor on the
panels is positioned to the specified folder.
At most 1299 bytes are read from the file "#filename#" to specify
the path to a directory or file.
When panels are turned off, the cursor is not positioned on the requested object,
only the switching to the required folder occurs.
See also: ~Contents~@Contents@ | ~Notes~@Remark@
@Ln
$ #諼á¡ñá Ln#
$ #The Ln command#
The #ln# command creates and deletes ~links~@:HardSymLink@
to files and folders. Hardlinks are created for files, symlinks are
created for folders. It is possible to mount local disks on file system
with #ln# command (so-called "volume mount points").
#ln# syntax:
#far:ln [/msg] [/n] source destination#
or
#ln:[/msg] [/n] source destination#
if "destination" is
a #file# : hardlink is created
a #folder# : symlink is crearted
a #drive# : drive is mounted in case of a "drive" sequence:
'drive_letter' ':' '\', e.g. "C:\"
switch #/msg# turns on the output of error messages
switch #/n# disables automatic update of panels after creation of link
Mounted drives (or volume mount points) is a Windows 2000/XP feature,
that allows to display specified disks as folders. Example:
#ln: E:\ C:\cdrom#
After this command the folder C:\cdrom will display the contents of drive E:
See also: ~Contents~@Contents@ | ~Remarks~@Remark@
@WhereIs
$ #The WhereIs command#
The #whereis# command locates the given object and jumps to it if the search was
successful.
#far:whereis filename#
or
#whereis:filename#
The search is performed in the following order:
1. Current folder
2. Windows 95: Windows' system foder (SYSTEM)
Windows NT: 32 bit Windows' system folder (SYSTEM32)
3. Windows NT: 16 bit Windows' system folder (SYSTEM)
4. Windows folder.
5. Folders in the system environment variable #PATH#
6. Contents of the registry key:
#HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\App Paths#
7. Contents of the registry key:
#HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\App Paths#
When panels are turned off, the cursor is not positioned on the requested object,
only the switching to the required folder occurs.
See also: ~Contents~@Contents@ | ~Notes~@Remark@
@Macro
$ #The Macro command#
The #macro# command loads macros from the registry or saves macros in the
registry. Also it can post the key sequence to FAR Manager as if they were
typed from the keyboard.
1. Load macros from the registry:
#far:macro load#
or
#macro:load#
2. Save macros to the registry:
#far:macro save#
or
#macro:save#
3. Post a key sequence:
#far:macro post sequence#
¿½¿
#macro:post sequence#
"sequence" is a sequence of key names as they are stored in
the registry by FAR Manager. For example:
macro:post F4 F12 0 Tab F4 F12 0
The sequence is executed only after return the FAR Manager receives control.
See also: ~Contents~@Contents@
@Direction
$ #Output Redirection#
Plugin can redirect the output of the specified #<command#.
#command# - #[stream][mode][|path|]command#.
#stream# - controls which output stream(s) to redirect.
#1# - redirect only standart output
stream #stdout#.
#2# - redirect only standart output
stream #stderr#.
#*# - redirect #stderr# and #stdout# as
one stream
#?# - redirect #stderr# and #stdout# as
different streams. For commands ~view~@View@
and ~edit~@Edit@ the streams will
be opened in separate windows. For other
commands same behavior as #*#.
#mode# - controls direct console output
(not via standard streams)
#># - ignore the console output of the
program and display only message
about its execution
#<# - save console output and make it
available for viewing with #Ctrl-O#,
#+# - same as #<#, but displays on the
screen redirected output of the program
along with console output.
#|path|# - command can be executed in the folder
defferent from the current one if this
parameter is present (enclosed in pipes #'|'#).
For example: '#edit:<|%TEMP%|dir#'.
Default values of #stream# and #mode# can be defined in
~plugin config~@Config@.
Progam output is placed in a temporary file. The output
can also be saved to a user-defined file:
#far:run filename<command#
#run:filename<command#
or opened
in viewer
#far:view <command#
#view:<command#
or in editor
#far:edit <command#
#edit:<command#
#far:edit[line] <command#
#edit:[line] <command#
#far:edit[line,column] <command#
#edit:[line,column] <command#
or the output can be placed into clipboard
#far:clip <command#
#clip:<command#
Notes:
1: The entire string after the symbol '#<#' and optional modifiers
is sent to the command processor (%COMSPEC%)
2. Temporary file is deleted automatically when FAR Manager
doesn't need it.
3. Some programs do not use standard output stream(s), but
print directly to the console. To store console output
and make it available for viewing with #Ctrl-O#, or to
ignore it, use modifiers '#<#', '#>#' ¿ '#+#'.
You can change default behavior in the ~configuration~@Config@.
See also: ~Contents~@Contents@ | ~Syntax~@Syntax@
@TheSameFolder
$^#Same Folder
To set the current folder of the passive panel to the same as
in the active one, choose the item "#Same Directory#" in the ~plugins menu~@:Plugins@
or in the ~drives menu~@:DriveDlg@.
See also: ~Contents~@Contents@ | ~Configuration~@Config@
@Remark
$^#Notes#
1. When using prefix #far# command names may be shortened to
their first letters. Example:
#far:v# is the same as #far:view# or #view:#
2. It is possible to enclose parameters #filename#,
#path# and #command# in quotes.
3. You can use environment variables.
4. If you make a syntax error, the help will pop up.
See also: ~Contents~@Contents@
@Config
$^#Configuring FAR Commands#
#"Add "Same Folder"# Adds the ~Same Folder~@TheSameFolder@ command
#to the Plugins menu"# to the ~Plugins menu~@:Plugins@.
#"Add "Same Folder"# Adds the ~Same Folder~@TheSameFolder@ command
#to the Disks menu"# to the ~Disks menu~@:DriveDlg@.
#External commands screen output# Control program screen output
#Hide external command# Hides program output. Only a message with
#output# the size of intercepted output will be
displayed. Same as using #<># instead of #<#.
#Keep external command# Saves the text output by programs directly
#output# to the console for viewing by#Ctrl-O#.
Same as using #<<# instead of #<#.
#Duplicate intercepted# Saves for viewing by #Ctrl-O# both the
#output to screen# direct console output and intercepted
output.
Same as using #<+# instead of #<#.
#Intercepting output# Controlling of program output interception:
#Intercept both# Intercept standart output stream #stdout#
#stdout and stderr# and standart error stream #stderr# as
one stream.
Same as using #<*# instead of #<#.
#Intercept stdout only# Intercept only #stdout#.
#(Standard output stream)# Same as using #<1# instead of #<#.
#Intercept stderr only# Intercept only #stderr#.
#(Standard errors stream)# Same as using #<2# instead of #<#.
#Intercept stdout and # Intercept stdout and #stderr#
#stderr separately# separately. It has sense only in
commands #far:view <# and #far:edit <#.
In other cases same as #<*#.
Can't be used with #<+#.
Same as using #<?# instead of #<#.
See also: ~Contents~@Contents@