zls
zls

zigtools/zls

MIT

A Zig language server supporting Zig developers with features like autocomplete and goto definition

3.0K 3.0K 299 115
7
build.zig.zon  build.zig 
View on Github  
Updated: 10:17:23 AM Wed Nov 20 2024 Size: 7724KB Created: 10:19:50 PM Fri Apr 24 2020
Dependencies:
No known dependencies
zig  fetch  --save  git+https://github.com/zigtools/zls

ZLS is a non-official implementation of the Language Server Protocol for Zig in Zig. It provides developers with IDE features in their editor.

Installation

The complete installation guide is available on the Zigtools website. It covers editor setup, prebuilt binaries and additional documentation.

Build From Source

Building ZLS requires a build of Zig master.

git clone https://github.com/zigtools/zls
cd zls
zig build -Doptimize=ReleaseSafe

When upgrading Zig, make sure to update ZLS too keep them in sync.

Features

ZLS supports most language features, including simple type function support, using namespace, payload capture type resolution, custom packages, cImport and others. Support for comptime and semantic analysis is Work-in-Progress.

The following LSP features are supported:

  • Completions
  • Hover
  • Goto definition/declaration
  • Document symbols
  • Find references
  • Rename symbol
  • Formatting using zig fmt
  • Semantic token highlighting
  • Inlay hints
  • Code actions
  • Selection ranges
  • Folding regions

Related Projects

Quick Thanks :)

We'd like to take a second to thank all our awesome contributors and donators/backers/sponsors; if you have time or money to spare, consider partaking in either of these options - they help keep ZLS awesome for everyone!