Skip to main content
OdooLS can be used in Neovim through nvim-lspconfig. The integration is maintained at github.com/odoo/odoo-neovim.
Unlike the VSCode and PyCharm integrations, the Neovim integration does not bundle the OdooLS server binary. You must install the server separately before configuring the LSP client.

Prerequisites

  • Neovim with nvim-lspconfig installed
  • The OdooLS server binary installed on your system
To get the OdooLS binary, either:

Setup

1

Install nvim-lspconfig

Add nvim-lspconfig to your Neovim plugin manager if you have not already. For example, with lazy.nvim:
{ "neovim/nvim-lspconfig" }
2

Configure the OdooLS language server

Add the following to your Neovim configuration to set up OdooLS:
require('lspconfig').odoo_ls.setup({
  -- your configuration here
})
Refer to the nvim-lspconfig documentation and the odoo-neovim repository for all available options.
3

Create a configuration file

Create an odools.toml file at the root of your Odoo project workspace. OdooLS uses this file to locate your Odoo installation and addon directories. See Configuration.
4

Open your project

Open a Python or XML file inside your Odoo project. The LSP client will start OdooLS and begin indexing your codebase.

Installing the server binary

Because the Neovim integration does not bundle the server, you need the odoo-ls binary on your PATH. See Installation for instructions on building the server from source using Cargo.
If you already use the VSCode extension on the same machine, you can locate the bundled binary inside the extension’s install directory and symlink it onto your PATH.

Build docs developers (and LLMs) love