nixvim icon indicating copy to clipboard operation
nixvim copied to clipboard

modules/colorscheme: Set colorscheme after everything else

Open mxkrsv opened this issue 1 year ago • 2 comments

Without that, e.g. require('gruvbox').setup() was run after setting the colorsheme. Thus all settings were ignored.

mxkrsv avatar Feb 20 '24 11:02 mxkrsv

Will this have any weird side effect with the highlights that we found from moving where in the config we set up highlights vs colorscheme? https://github.com/nix-community/nixvim/pull/1016 for reference

khaneliman avatar Feb 22 '24 21:02 khaneliman

I'm not sure I want to unilaterally change the colorscheme setup, as I believe it's better to set them up early in the init.lua.

I think what we should do is create a new option extraColorschemeLua that would contain all the code for the setup of the selected colorscheme(s) and after this section we could add the vim.cmd.colorscheme("${config.colorscheme}") statement.

traxys avatar Feb 28 '24 21:02 traxys

Without that, e.g. require('gruvbox').setup() was run after setting the colorsheme. Thus all settings were ignored.

I am rewriting all of the colorschemes.* plugin modules. With the new method, this ordering problem should not exist anymore.

Could you test if gruvbox now works fine please ?

GaetanLepage avatar Apr 07 '24 15:04 GaetanLepage

I am rewriting all of the colorschemes.* plugin modules. With the new method, this ordering problem should not exist anymore.

Could you test if gruvbox now works fine please ?

Works now, thanks!

mxkrsv avatar Apr 07 '24 16:04 mxkrsv