DLS Configuration

The details below describe how to install and configure the D language server found here.
NOTE: This installation process assumes the D compiler has been installed on the machine.

Building the Language Server

To build the language server you are going to need the D compiler and it's associated tool set.
Start by opening a command prompt and downloading the language server using the following command:
C:\dlang>dub fetch dls
This should result in the following output:
Fetching dls 0.21.10...
Please note that you need to use `dub run ` or add it to dependencies of your package to actually use/run it. dub does not do actual installation of packages outside of its own ecosystem.
Build the language server using the following command:
C:\dlang>dub run dls:bootstrap
This should result in the following output:
Building package dls:bootstrap in C:\Users\UserId\AppData\Local\dub\packages\dls-0.13.2\dls\bootstrap\
Running pre-generate commands for dls:i18n...
Performing "debug" build using C:\dlang\dmd\windows\bin\dmd.exe for x86.
dls:protocol 0.13.2: target for configuration "library" is up to date.
dls:i18n 0.13.2: building configuration "library"...
dls:bootstrap 0.13.2: building configuration "application"...
Linking...
To force a rebuild of up-to-date targets, run again with --force.
Running ..\Users\UserId\AppData\Local\dub\packages\dls-0.13.2\dls\bootstrap\dls_bootstrap.exe
C:\Users\UserId\AppData\Local\dub\packages\.bin\dls-latest\dls.exe
Take note of the last line of that output as it contans the location of the language server binary and this information will be used in the configuration step that follows.

Configuration

Start Zeus and use the Options, Document Types menu to edit the D document type and in the Language Server panel apply the following configuration settings:
Program Type: Executable
     Program: dls.exe
   Directory: C:\Users\UserId\AppData\Local\dub\packages\.bin\dls-latest\
   Arguments: --stdio
NOTE: The executable directory option used above can be omitted provided the executable folder is found in the system PATH environment variable.

Using the Language Server

To test the configuration create a simple test.d file and fire off an auto-complete request:
lsp d


Latest Version: Zeus 3.99b
Released: 29th January 2024