External Editor and Import Script tool

Use an external editor to create new or open existing Tcl files. Then, import the modified or generated Tcl script files back to the IDE using the Import Script tool.

Configuration of the external editor is specified on the Client Preferences > External Command tab.

Note:  If you do not configure the external editor, then the default editor is used.

To configure an external editor to edit Tcl files that are selected from the Site Manager :

  1. Specify a @F placeholder in the command line.
    For example, to edit a file using Windows Notepad, specify:
    notepad @F
  2. If you use an external editor that does not create its own dialog box when it starts, then you must create a dialog box as part of the command line.
    • On Windows clients:
      cmd /c start vi.exe
    • On UNIX clients:
      xterm -e vi
  3. Configure the command line to invoke the external editor with correct parameters.
  4. When you specify the command line and click OK, there is validation to ensure no opened script files are in the built-in editor.
    If any opened script files exist, then a message box opens asking you to close all opened scripts.
  5. After specifying the external editor, you can use that editor to open or create new Tcl files.

    To create a new file, launch the external editor from the Launch Bar.

    For existing Tcl files, double-click the specified Tcl file from the Site Manager tree.

  6. At this point, there is another validation to ensure the command is running correctly during runtime when the editor is invoked.
    For an existing Tcl file, the file is copied to a temporary directory under %HCIROOT%\integrator\temp\hostname\sitename\ in the IDE with the specified script name.

    For a new Tcl file, the editor is directly invoked with the working directory set to be the temporary folder. You must specify an appropriate file name when saving the new file.

    If the editor cannot be run correctly, then an error message is shown.

  7. Click Import on the IDE to import the modified or generated Tcl script file to the IDE.
    A file browser opens for you to select the imported file path.
    If any selected files have been opened and modified with the IDE’s built-in editor or are locked, then an error message displays and stops the import.
  8. The selected files are imported into the current open site.
    If there are existing script files with the same name, then a message box opens asking to overwrite it.
  9. After the import is permitted, all of the actions that the IDE’s built-in editor can do are available. That is, importing performs any required transformation, compilation, remote saving, and other tasks that the IDE’s build-in editor performs.