DVT IDE for VS Code VHDL User Guide
Rev. 23.1.3, 31 January 2023

24.2.1 dvt_ls.sh Syntax

Usage: dvt_ls.sh start | stop | list | version | help ...

  Start a language server:
    start | createProject <project path> -lang <lang> [-name <name>]
                          [-build <name>] [-f|-F <file>] [-<name>.build <....>]
                          [-map <name> <path>] [-local]
                          [-heap_size <size>] [-stack_size <size>] [-vmargs <args>]
                          [-noexit]

      Mandatory arguments:
        <project path>        Path to project (must exist).
        -lang   <lang>        Project language (vlog, vhdl).

      Optional arguments:
        -name         <name>  Friendly name for this language server.
        -build        <name>  Name of active build configuration.
        -f|-F         <file>  Specify a command file for the project. -f and -F are mutually exclusive.
        -<name>.build <....>  Create the build configuration file <project>/.dvt/<name>.build with <....> as content.
                              All flags up to the end of the command line, or up to the next -<name>.build flag are considered build.
                              configuration directives. This flag cannot be used in conjunction with -f, or -F.
        -map   <name> <path>  Specify additional folders to be opened in the Language Server's client at connection time.
        -local                Language server will bind to the '127.0.0.1' address, only connections from the same machine will be accepted.
        -heap_size    <size>  Set the Java heap size (syntax is <N>[g|G|m|M|k|K]). Default is 3072m.
        -stack_size   <size>  Set the Java thread stack size (syntax is <N>[g|G|m|M|k|K]). Default is 4m.
        -vmargs       <args>  Additional Java arguments.
        -noexit               Script will not terminate after the language server is started, terminating the script will also terminate the language server.

  Stop language servers:
    stop -id <id>* | -available
      -id <id>              Stop all servers with the specified ids.
      -available            Stop all unused servers.

  List language servers:
    list [-id <id>* | -available]
      -id <id>              Show info about the servers with the specified ids.
      -available            Show info about unused servers.

  Show language server version:
    version

If the server successfully starts it will print out the ID of the started server.

Notes about arguments

  • When no build <name> is specified, the server will use the default build configuration (default.build file). If it doesn't exists it will be created with the auto-config directive inside of it.

  • When no lang <lang> is specified, the server will use the values available in the <name>.ls file and if missing it will automatically infer the languages used in your project from:

    • the nature directive in of an Eclipse .project file when migrating a project from DVT Eclipse

    • the top files specified in the <name>.build

    • the file extensions present under the project folder

  • Arguments lang, heap_size, stack_size, vmargs will be saved in a <name>.ls file when starting the server, where <name> is the name of the build configuration used to start the server. If no values are provided for these arguments the default or inferred values will be saved.

  • The name argument can be used to give a friendly name to the newly started Language Server. This name will be visible in the DVT Language Servers View and can be used as an argument of the dvt_code.sh connect ... command.

  • To restrict access to the Language Server use local argument, this way the server is bound to localhost and only can be used only by UIs started on the same host.

  • By default servers are started as a daemon, the dvt_ls.sh command ends after the server is detached from the script. In some situation (e.g. when dispatching the job into a computer farm) it is preferable to run the server as a foreground job in which case noexit flag must be used.