Skip to content

Usage in Neovim

bash
nvim path/to/rtl.sv

Run :LspInfo to confirm the lazyverilog client is attached. Not installed yet? See Install for Neovim.

Keymaps

Use your existing LSP keymaps, or add:

lua
vim.keymap.set("n", "gd", vim.lsp.buf.definition)
vim.keymap.set("n", "gr", vim.lsp.buf.references)
vim.keymap.set("n", "K", vim.lsp.buf.hover)
vim.keymap.set("n", "<leader>rn", vim.lsp.buf.rename)
vim.keymap.set({ "n", "v" }, "<leader>ca", vim.lsp.buf.code_action)

The code action menu offers AutoInst, AutoWire, AutoArg, AutoFunc, and AutoFF when the cursor is on a supported construct.

Commands

CommandDescription
:FormatFormat the buffer or visual range
:LintShow diagnostics for the buffer
:LintAllShow diagnostics for all indexed project files
:RtlTreeOpen the module hierarchy
:RtlTreeReverseOpen the reverse hierarchy from the current module
:Interface <inst>Inspect one instance (Interface)
:Interface <inst1> <inst2>Inspect and edit connections between two instances
:Connect <module1> <module2>Connect two modules through the hierarchy (Connect)

Released under the MIT License. Themed with Catppuccin.