github.com/ocaml/ocaml-lsp ↗
OCaml Language Server Protocol implementation
An animated visualization of ocaml/ocaml-lsp's Git history from January 2019 to January 2021, built by 41 contributors. The codebase reached 2,861 lines, mostly OCaml. The video runs 1 minute 5 seconds.
Render your own repo
Turn any GitHub repository into a video like this — free sample in seconds.
Open this visualization on its own page →
Language
OCaml
Contributors
41
Lines of Code
2,861
From
2019-01-28
To
2021-01-03
Advertisement
About ocaml/ocaml-lsp
OCaml-LSP is an implementation of the Language Server Protocol for OCaml that enables IDE integration and editor support for OCaml development. The project provides the `ocamllsp` binary, which allows text editors and IDEs to offer features like code completion, hover information, go-to-definition, refactoring, and diagnostics for OCaml code. It can be installed via opam, esy, or Dune's package management system, and integrates well with the Dune build system through RPC communication.
The server supports a comprehensive range of LSP features including semantic highlighting, document formatting, code lensing, symbol navigation, and renaming. Beyond standard LSP capabilities, OCaml-LSP provides OCaml-specific extensions such as switching between implementation and interface files, inferring interfaces, locating typed holes, and generating exhaustive pattern matching through code actions. The project also includes experimental features for constructing values by type and displaying syntax documentation on hover.
OCaml-LSP is particularly well-integrated with the Visual Studio Code platform through the OCaml Platform extension, though it works with any LSP-compatible editor. The project vendors Merlin internally to provide "smart" functionality even when source code doesn't compile, eliminating the need for users to separately install Merlin. Development is active with comprehensive test coverage and a changelog-driven contribution process.
Advertisement