« Back to Index

Zig: Install LSP

View original Gist on GitHub

Tags: #lsp #zig #zls

Install Zig and the zls LSP.bash

# reinstall the latest zig
brew uninstall --force zig
brew install zig --HEAD
zig version # at the time of writing: 0.9.0-dev.954+c4f97d336

# then build zls from source:
git clone --recurse-submodules https://github.com/zigtools/zls
cd zls
zig build -Drelease-safe
./zig-out/bin/zls config 

# finally add zls executive path to your .rc file
PATH="$HOME/zig/zig-out/bin:$PATH"