.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
                 ~link~@Link@      - create links
                 ~run~@Run@     - execute commands
                 ~load~@Load@   - load plugin
                 ~unload~@Unload@ - unload plugin

   #<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#'.

   Команды #load# и #unload# доступны только в Unicode-версии (для FAR 2.x)

   See also: ~Contents~@Contents@ | ~Output Redirection~@Direction@ | ~Notes~@Remark@

@Load
$ #The Load command#
   Команда #load# позволяет загрузить плагин #имя_DLL_модуля#.

   #far:load имя_DLL_модуля#
   #load:имя_DLL_модуля#

   Команда доступна только в Unicode-версии (для FAR 2.x)

   See also: ~unload~@Unload@ | ~Notes~@Remark@

@Unload
$ #The Unload command#
   Команда #unload# позволяет загрузить плагин #имя_DLL_модуля#.

   #far:unload имя_DLL_модуля#
   #unload:имя_DLL_модуля#

   Команда доступна только в Unicode-версии (для FAR 2.x)

   See also: ~Load~@load@ | ~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@

@Link
$ #The Link command#

   The #link# command creates and deletes ~links~@:HardSymLink@
to files and folders. Hardlinks are created for files, directory junction are
created for folders. It is possible to mount local disks on file system
with #link# command (so-called "volume mount points").

   #link# syntax:

   #far:link [/msg] [/n] [/s] source destination#
   or
   #link:[/msg] [/n] [/s] source destination#

   if "destination" is

     a #file#   : hardlink is created
     a #folder# : symlink is created
     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

   Ключ #/s# создает символическую ссылку-файл (вместо жесткой связи)
или ссылку-каталог (вместо связи каталогов). Ключ актуален в Windows Vista
или выше. Игнорируется при монтировании дисков.

   Mounted drives (or volume mount points) is a Windows 2000/XP feature,
that allows to display specified disks as folders. Example:

   #link: 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. Каталог, на котрый указывает переменная среды %FARHOME%
   3. Windows 95: Windows' system folder (SYSTEM)
      Windows NT: 32 bit Windows' system folder (SYSTEM32)
   4. Windows NT: 16 bit Windows' system folder (SYSTEM)
   5. Windows folder.
   6. Folders in the system environment variable #PATH#
   7. Contents of the registry key:
      #HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\App Paths#
   8. 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#
      or
      #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@, ~Macro~@:KeyMacroCmds@

@Direction
$ #Output Redirection#
   The plugin can redirect the output of the specified #"<command"# or #"<<command"#.

   #command#   - #[stream][mode][|path|]command#.

               #stream# - controls which output stream(s) to redirect.
                        #1# - redirect only standard output
                            stream #stdout#.
                        #2# - redirect only standard 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
                        different 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@.

   Program 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 '#<#', '#>#' and '#+#'.
      You can change default behavior in the ~configuration~@Config@.

   4. If the stream parameter equals 1 or 2 then the start of the
      command text must be separated from it by some symbol.

      Example:
      Execute the command "1" and redirect its output to the editor.
               edit:<1
               possible cases with the parameter stream=1
               edit:<1 1
               edit:<1"1"
               edit:<1+1
               edit:<1|%TEMP%|1

   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.

   5. You can use console aliases as #command#
      (Console aliases - macros defined by command DOSKEY)

   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
   #output#                      with the size of intercepted output
                               will be displayed. Same as using #<>#
                               instead of #<#.

   #Keep external command#       Saves the text output by programs
   #output#                      directly 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 standard output stream
   #stdout and stderr#           #stdout# and standard 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 #<#.

 #View/edit empty files#         With this options off, zero sized
                               files will not be opened for viewing
                               or editing.

 #Edit new files#                Allows to open the editor with non
                               existing files.


   See also: ~Contents~@Contents@
