Note: I am already addressing this and will submit a PR soon. This issue is here for reference.
The Bug
What is says on the tin. Setting darkvoid as the colorscheme when using LazyVim throws the following error:
Error 12:42:29 AM notify.error lazy.nvim Failed to run `config` for bufferline.nvim
...re/nvim/lazy/LazyVim/lua/lazyvim/plugins/colorscheme.lua:58: attempt to index field 'colors_name' (a nil value)
This is because LazyVim's colorscheme.lua (part of the default config stored in ~/.local/share/nvim) always runs the following snippet:
if vim.g.colors_name:find("catppuccin") then
opts.highlights = require("catppuccin.groups.integrations.bufferline").get()
end
While this isn't a real problem necessarily in that it doesn't affect functionality, seeing an error message every time launching Neovim is 1. inelegant, 2. may cause some users to think something is wrong, prompting them to uninstall the theme.
The Reason
The reason is because darkvoid doesn't set vim.g.colors_name in init.lua, which seems to be common practice among other colorscheme plugins.
My Proposed Solution
I propose simply setting vim.g.colors_name to darkvoid in init.lua.
This change should not break anything, and it should make darkvoid compatible with more users' Neovim setups, such as LazyVim users.
The Bug
What is says on the tin. Setting darkvoid as the colorscheme when using LazyVim throws the following error:
This is because LazyVim's
colorscheme.lua
(part of the default config stored in~/.local/share/nvim
) always runs the following snippet:While this isn't a real problem necessarily in that it doesn't affect functionality, seeing an error message every time launching Neovim is 1. inelegant, 2. may cause some users to think something is wrong, prompting them to uninstall the theme.
The Reason
The reason is because darkvoid doesn't set
vim.g.colors_name
ininit.lua
, which seems to be common practice among other colorscheme plugins.My Proposed Solution
I propose simply setting
vim.g.colors_name
todarkvoid
ininit.lua
.This change should not break anything, and it should make darkvoid compatible with more users' Neovim setups, such as LazyVim users.