A simple lualine component for CodeCompanion, providing a status indicator with the number of active CodeCompanion requests.
- Displays the number of active CodeCompanion requests.
- Shows a spinner while requests are active, and a checkmark (✓) when idle.
- Includes an icon and can be customized.
With lazy.nvim:
return {
"nvim-lualine/lualine.nvim",
dependencies = {
"franco-ruggeri/codecompanion-lualine.nvim",
-- Other dependencies
},
opts = {
sections = {
lualine_x = {
"codecompanion",
-- Other components
},
},
},
}
The component will be enabled only after CodeCompanion is loaded, respecting its lazy-loading options. Thus, it is recommended that you do not add CodeCompanion as a dependency of lualine.
You can customize the component by passing the following options:
require('lualine').setup {
sections = {
lualine_x = {
{
"codecompanion",
icon = " ",
spinner_symbols = { "⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏" },
done_symbol = "✓",
},
},
},
}
This plugin is based on the example from the official documentation.