diff --git a/home/programs/neovim/default.nix b/home/programs/neovim/default.nix index 605806f..9c34efb 100644 --- a/home/programs/neovim/default.nix +++ b/home/programs/neovim/default.nix @@ -5,39 +5,42 @@ programs.neovim = { enable = true; + withNodeJs = true; + withPython3 = true; - plugin = with pkgs.vimPlugins; [ + plugins = with pkgs.vimPlugins; [ lazy-nvim - + catppuccin-nvim ]; extraLuaConfig = '' vim.g.mapleader = " " - require("lazy").setup({ - spec = { - -- Import plugins from lua/plugins - { import = "plugins" }, + require("plugins") + require("lazy").setup({ + spec = { + -- Import plugins from lua/plugins + { import = "plugins" }, + }, + performance = { + reset_packpath = false, + rtp = { + reset = false, + } }, - performance = { - reset_packpath = false, - rtp = { - reset = false, - } - }, - dev = { - path = "${ - pkgs.vimUtils.packDir - config.programs.neovim.finalPackage.passthru.packpathDirs - }/pack/myNeovimPackages/start", - patterns = {"folke", "catppuccin"}, - }, - install = { - -- Safeguard in case we forget to install a plugin with Nix - missing = false, - }, - }) - require("config/options") + dev = { + path = "${ + pkgs.vimUtils.packDir + config.programs.neovim.finalPackage.passthru.packpathDirs + }/pack/myNeovimPackages/start", + patterns = {"folke", "catppuccin"}, + }, + install = { + -- Safeguard in case we forget to install a plugin with Nix + missing = false, + }, + }) + require("config/options") ''; }; diff --git a/home/programs/neovim/lua/config/options.lua b/home/programs/neovim/lua/config/options.lua index c434403..8be5665 100644 --- a/home/programs/neovim/lua/config/options.lua +++ b/home/programs/neovim/lua/config/options.lua @@ -11,4 +11,3 @@ opt.shiftwidth = 2 -- Size of an indent opt.smartindent = true -- Insert indents automatically opt.spelllang = { "en" } opt.tabstop = 2 -- Number of spaces tabs count for - diff --git a/home/programs/neovim/lua/plugins/colorscheme.lua b/home/programs/neovim/lua/plugins/colorscheme.lua new file mode 100644 index 0000000..0443e8d --- /dev/null +++ b/home/programs/neovim/lua/plugins/colorscheme.lua @@ -0,0 +1,48 @@ +return { + { + "catppuccin/nvim", + lazy = false, + name = "catppuccin", + priority = 1000, + config = function() + vim.cmd.colorscheme("catppuccin") + end, + opts = { + integrations = { + nvimtree = true, + dashboard = true, + which_key = true, + cmp = true, + markdown = true, + leap = true, + telescope = { + enabled = true, + }, + treesitter = true, + rainbow_delimiters = true, + dropbar = { + enabled = false, + color_mode = false, -- enable color for kind's texts, not just kind's icons + }, + native_lsp = { + enabled = true, + virtual_text = { + errors = { "italic" }, + hints = { "italic" }, + warnings = { "italic" }, + information = { "italic" }, + }, + underlines = { + errors = { "underline" }, + hints = { "underline" }, + warnings = { "underline" }, + information = { "underline" }, + }, + inlay_hints = { + background = true, + }, + }, + }, + }, + }, +}