Skip to main content

Documentation Index

Fetch the complete documentation index at: https://trunk-4cab4936-sam-gutentag-flaky-tests-new-monitors.mintlify.app/llms.txt

Use this file to discover all available pages before exploring further.

📘 The Trunk Code Quality Neovim Plugin is available for beta!Try it out by following the instructions below.

Prerequisites

The Neovim Plugin needs the following prerequisites:
ToolMinimum Required Version
CLI1.17.0
Neovimv0.9.2

Get started

Using the lazy.nvim plugin manager:
require("lazy").setup({
	{
		"trunk-io/neovim-trunk",
		lazy = false,
		-- optionally pin a version
		tag = "v0.1.3",
		-- these are optional config arguments (defaults shown)
		config = {
			-- trunkPath = "trunk",
			-- lspArgs = {},
			-- formatOnSave = true,
                        -- formatOnSaveTimeout = 10, -- seconds
			-- logLevel = "info"
		},
		main = "trunk",
		dependencies = {"nvim-telescope/telescope.nvim", "nvim-lua/plenary.nvim"}
	}
})
For other plugin managers and installation methods, see our Neovim Plugin repo.

Features

The Neovim Plugin is designed to mirror the VSCode extension. Supported features include:
  • Provide inline diagnostics and auto-fixes
  • Format files on save
  • Run Trunk Actions notifications
  • Display the linters that Trunk runs on a file

Limitations

The Trunk Code Quality Neovim Plugin is in beta with limited support. If you encounter any issues, feel free to reach out on Slack. For other notes and configuration, see the Neovim Plugins repo.