shaunsingh / nord.nvim

Neovim theme based off of the Nord Color Palette, written in lua with tree sitter support
GNU General Public License v2.0
854 stars 112 forks source link

support for lazy? #159

Open bckelley opened 3 months ago

bckelley commented 3 months ago

question in the title I use lazy for plugins wondering if it will be supported?

EvanKoe commented 2 months ago

Hi @bckelley ! I don't know if by "support for lazy" you mean, lazy-loading this plugin, which is not very useful as it is a theme, but if you only want to install this plugin through Lazy without lazy-loading it, you should do:

Add a lua/USER/plugins/themes.lua file

It is going to download the theme from that repository, disable the lazy-loading (lazy = false. Put it to true if you want it to be lazy loaded), and apply the theme with the colorscheme vim function:

return {
    'shaunsingh/nord.nvim',
    lazy = false,
    priority = 1000,
    config = function ()
        vim.cmd('colorscheme nord')
    end
}

Restart your nvim and let lazy do the heavy lifting

It should display a window that shows you Lazy downloading Nord.

Bonus: Lualine

If you are using lualine, you may want to add the Nord theme to it as well. Go to lua/USER/plugins/lualine.lua and change the theme = option:

return {
  'nvim-lualine/lualine.nvim',
  dependencies = { 'nvim-tree/nvim-web-devicons' },
  config = function()
    local lazy_status = require("lazy.status")
    require("lualine").setup({
      options = {
        -- here
        theme = "nord",  
      },
...

Hope that will help !

Actually, I'm pretty sure, even if it does not help you, that it's gonna help me in 6 months when I'll want to change my theme and won't remember how to do it :')