Skip to content

How to install servers

Daniel S Poulin edited this page Sep 16, 2019 · 29 revisions

This is a short reference for installation of language servers listed in default kak-lsp.toml configuration.


rustup component add rls-preview rust-analysis rust-src



git clone
cd scry
shards build
ln -s $PWD/bin/scry ~/.local/bin



filetypes = ["crystal"]
roots = ["shard.yml"]
command = "scry"

C, C++


kak-lsp supports semantic highlighting using cquery.

If you prefer ccls, change language.c_cpp section in kak-lsp to something like this:

filetypes = ["c", "cpp"]
roots = ["compile_commands.json", ".ccls", ".git"]
command = "ccls"

and refer for installing and configuring ccls itself.

kak-lspsupports nearly all ccls lsp extensions, including semantic highlighting, navigations, and special cross references. See the ccls-{navigate,vars,inheritance,member,call} kak functions for a reference. They are also described in the ccls wiki.

JavaScript + Flow

npm install -g flow-bin


npm install -g typescript
npm install -g typescript-language-server
filetypes = ["typescript"]
roots = ["package.json"]
command = "typescript-language-server"
args = ["--stdio"]

or alternatively Sourcegraphs implementation:

npm install -g typescript
npm install -g javascript-typescript-langserver

filetypes = ["typescript"]
roots = ["package.json", "tsconfig.json"]
command = "javascript-typescript-stdio"


npm install -g vscode-{html,css,json}-languageserver-bin

OCaml, ReasonML

npm install -g ocaml-language-server




pip install 'python-language-server[all]'

python-language-server does not currently use initialization options python-language-server#403, so you can not configure it via kak-lsp.toml. Instead, use the lsp_server_configuration option in your kakrc:

set-option global lsp_server_configuration pyls.configurationSources=["flake8"]


By default kak-lsp uses bingo language server, which supports Go modules.

See for installation instructions.

If you prefer using go-langserver, install it with

go get -u

and then use the following config in your kak-lsp.toml:

filetypes = ["go"]
roots = ["Gopkg.toml", "go.mod", ".git", ".hg"]
command = "go-langserver"
args = ["-mode", "stdio", "-gocodecompletion"]

PHP (Intelephense)

Install the server component globally using npm:

npm i -g intelephense

Then in kak-lsp.toml add the following, where <path-to-intelephense> is the output of which intelephense:

filetypes = ["php"]
roots = ["composer.json"]
command = "node"
args = ["<path-to-intelephense>"]

PHP (PHP Language Server)

Install globally according to the installation instructions. For ArchLinux you may install through the AUR:

Then in kak-lsp.toml add

filetypes = ["php"]
roots = ["composer.json"]
command = "php"
args = ["path/to/php-language-server.php"]

Where you change path/to/php-language-server.php to the path to the php-language-server.php file. You can use composer g show felixfbecker/language-server to get the path to the global installation, then append bin/php-language-server.php to get the path.

PHP (Psalm)

Install it to your project according to the installation instructions. Once installed, you can configure your kak-lsp.toml as follows:

filetypes = ["php"]
roots     = ["composer.json"]
command   = "php"
args      = ["vendor/bin/psalm-language-server"]

Despite not being an absolute path, this will still work as the context of execution of the php command is where your composer.json file is.


npm i -g bash-language-server



pub global activate dart_language_server


Install the D Language Server by running dub fetch dls, then dub run dls:bootstrap. The second command will print the location where dub installed the server. You will need to place this executable on your path, e.g. by making the path absolute (dub will likely print a relative path) and creating a symlink sudo ln -s <absolute path to dls> /usr/local/bin/dls.


nimble install nimlsp

filetypes = ["nim"]
roots = ["*.nimble", ".git"]
command = "nimlsp"
args = ["path/to/nim/installation"] # optional (if installed from nimble or path wasn't provided at compiletime)


You may be able to install the elm-language-server with npm:

`npm install -g elm-language-server'

If this doesn't work, or to install the latest version of the elm-language-server, clone the repo and compile it:

git clone
cd elm-language-server
npm install
npm run compile
npm link

Then, you should be able to run the language server with the following command:

elm-language-server --stdio

Installation of elm-test and elm-format is normally done with npm:

npm install -g elm-test
npm install -g elm-format
You can’t perform that action at this time.