Configuration for my NixOS based systems and Home Manager
at mikoto 332 lines 9.1 kB view raw
1-- Bootstrap lazy.nvim 2local ensure_lazy = function() 3 local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim" 4 if not vim.loop.fs_stat(lazypath) then 5 vim.fn.system({ 6 "git", "clone", "--filter=blob:none", 7 "https://github.com/folke/lazy.nvim.git", "--branch=stable", -- latest stable release 8 lazypath 9 }) 10 end 11 vim.opt.rtp:prepend(lazypath) 12end 13 14local lazy_bootstrap = ensure_lazy() 15if lazy_bootstrap then print("Bootstrapped lazy.nvim") end 16 17require("lazy").setup({ 18 install = { colorscheme = { "nord" } }, 19 checker = { enabled = false }, 20 spec = { 21 -- Color themes 22 { "shaunsingh/nord.nvim", priority = 1000, lazy = true }, 23 { "shaunsingh/moonlight.nvim", priority = 1000, lazy = true }, 24 { "folke/tokyonight.nvim", priority = 1000, lazy = true }, 25 { "cranberry-clockworks/coal.nvim", priority = 1000, lazy = true }, 26 { "hardselius/warlock", priority = 1000, lazy = true }, 27 { "sontungexpt/witch", priority = 1000, lazy = true, config = true }, 28 { "rose-pine/neovim", priority = 1000, lazy = true }, 29 { "catppuccin/nvim", name = "catppuccin", priority = 1000, lazy = true }, 30 { 31 "neanias/everforest-nvim", 32 version = false, 33 lazy = true, 34 priority = 1000, -- make sure to load this before all the other start plugins 35 main = "everforest", 36 opts = { background = "hard" } 37 }, 38 { "rebelot/kanagawa.nvim", opts = { compile = true }, priority = 1000, lazy = true }, 39 { 40 'jesseleite/nvim-noirbuddy', 41 dependencies = { 42 'tjdevries/colorbuddy.nvim', 43 'nvim-lualine/lualine.nvim' 44 }, 45 lazy = true, 46 priority = 1000, 47 config = function(_, opts) 48 -- configure lualine 49 require('noirbuddy').setup(opts) 50 local noirbuddy_lualine = require("noirbuddy.plugins.lualine") 51 require("lualine").setup { 52 options = { 53 icons_enabled = true, 54 --theme = "auto" 55 theme = noirbuddy_lualine.theme 56 }, 57 sections = noirbuddy_lualine.sections, 58 inactive_sections = noirbuddy_lualine.inactive_sections, 59 } 60 end, 61 opts = { 62 -- All of your `setup(opts)` will go here 63 preset = "oxide", 64 colors = { 65 noir_8 = "#3A4649" 66 } 67 }, 68 }, 69 { 70 "plan9-for-vimspace/acme-colors" 71 }, 72 -- Completion 73 { 74 "hrsh7th/nvim-cmp", 75 dependencies = { 76 "hrsh7th/cmp-nvim-lsp", 77 "hrsh7th/cmp-buffer", 78 "hrsh7th/cmp-path", 79 "hrsh7th/cmp-vsnip", 80 "hrsh7th/vim-vsnip", 81 "petertriho/cmp-git", 82 "hrsh7th/cmp-cmdline" 83 }, 84 config = require('completion') 85 }, -- nvim lsp plugins 86 { 87 "neovim/nvim-lspconfig", 88 }, 89 -- LSP Goodness 90 { 91 "ray-x/navigator.lua", 92 dependencies = { 93 { 'ray-x/guihua.lua', build = 'cd lua/fzy && make' }, 94 { 'neovim/nvim-lspconfig' }, 95 } 96 97 }, 98 { 99 -- Syntax Highlighting from the future 100 "nvim-treesitter/nvim-treesitter", 101 --init = function() vim.cmd([[":TSUpdate"]]) end, 102 main = "nvim-treesitter.configs", 103 opts = { 104 ensure_installed = 'all', 105 ignore_install = { 'norg' }, 106 sync_intall = true, 107 highlight = { 108 enable = true, 109 }, 110 indent = { 111 enable = false, 112 }, 113 }, 114 build = ":TSUpdate", 115 version = false, 116 dependencies = { 117 "nvim-treesitter/nvim-treesitter-textobjects", 118 "nvim-treesitter/nvim-treesitter-context", 119 }, 120 }, -- Git stuff 121 -- GitGutter, shows inline difs 122 "airblade/vim-gitgutter", 123 { 124 "NeogitOrg/neogit", 125 dependencies = { 126 "nvim-lua/plenary.nvim", -- required 127 "sindrets/diffview.nvim", -- optional - Diff integration 128 "nvim-telescope/telescope.nvim" 129 }, 130 config = true 131 }, 132 -- Auto format tool 133 { 134 "stevearc/conform.nvim", 135 lazy = true, 136 opts = { 137 python = { "isort", "black" }, 138 lua = { "lua-format" }, 139 clojure = { "cljfmt" }, 140 rust = { "rustfmt" }, 141 haskell = { "ormolu", "stylish-haskell" }, 142 go = { "goimports", "gofmt" }, 143 java = { "google-java-format" }, 144 javascript = { "prettier" }, 145 html = { "prettier" }, 146 yaml = { "prettier" }, 147 sh = { "shfmt" }, 148 c = { "clang-format" }, 149 } 150 }, 151 { 152 "hedyhli/outline.nvim", 153 lazy = true, 154 cmd = { "Outline", "OutlineOpen" }, 155 config = true, 156 keys = { 157 { "<leader>o", "<cmd>Outline<cr>", desc = "Toggle outline" }, 158 }, 159 }, 160 { 161 "ray-x/go.nvim", 162 ft = "go", 163 lazy = true, 164 dependencies = { 165 "ray-x/guihua.lua", "neovim/nvim-lspconfig", 166 "nvim-treesitter/nvim-treesitter" 167 } 168 }, 169 { 170 "nvim-lualine/lualine.nvim", 171 config = true, 172 dependencies = { "nvim-tree/nvim-web-devicons" } 173 }, 174 -- Fuzzy finding stuff 175 --"junegunn/fzf.vim", 176 "ibhagwan/fzf-lua", 177 -- A lua + nvim stdlib sort of thing 178 { "nvim-lua/plenary.nvim", lazy = true, }, 179 -- Telescope, find anything fast 180 { 181 "nvim-telescope/telescope.nvim", 182 config = true, 183 dependencies = { 184 "nvim-lua/plenary.nvim", 185 "nvim-telescope/telescope-symbols.nvim", 186 "nvim-telescope/telescope-fzf-native.nvim" 187 } 188 }, 189 { 190 "folke/trouble.nvim", 191 dependencies = "nvim-tree/nvim-web-devicons", 192 config = true, 193 }, 194 -- Which key is bound? 195 -- literally the best plugin ever 196 { 197 "folke/which-key.nvim", 198 init = function() 199 vim.o.timeout = true 200 vim.o.timeoutlen = 300 201 end, 202 config = true 203 }, 204 -- Developing my neovim 205 { 206 "folke/lazydev.nvim", 207 config = true, 208 ft = "lua", 209 lazy = true, 210 opts = { 211 library = { 212 path = "luvit-meta/library", words = { "vim%.uv" }, 213 }, 214 }, 215 dependencies = { 216 "Bilal2453/luvit-meta" 217 }, 218 }, 219 -- Lithsps 220 { 221 "windwp/nvim-autopairs", 222 event = "InsertEnter", 223 config = function() 224 local pairs = require("nvim-autopairs") 225 226 pairs.setup({ 227 check_ts = true, 228 enable_check_bracket_line = false, 229 }) 230 231 pairs.get_rules("`")[1].not_filetypes = { "clojure", "scheme", "scm", "janet" } 232 pairs.get_rules("'")[1].not_filetypes = { "clojure", "scheme", "scm", "janet", "rust" } 233 end, 234 }, 235 -- This gives me the paredit engine, it's pretty nifty 236 { 237 "gpanders/nvim-parinfer", 238 ft = { "hy", "scheme", "scm", "clojure", "fennel", "janet", "lisp", "python", "lua" }, 239 lazy = true, 240 config = function() 241 --vim.g.parinfer_comment_chars = { ";" } 242 vim.g.parinfer_force_balance = true 243 end 244 }, -- )))))) 245 -- This one gives me vim-sexp like structural editing 246 { 247 "julienvincent/nvim-paredit", 248 config = function() 249 local paredit = require('nvim-paredit') 250 paredit.setup({ 251 indent = { 252 enabled = true, 253 }, 254 filetypes = { "clojure", "fennel", "janet" }, 255 }) 256 end, 257 lazy = true, 258 ft = { "hy", "scheme", "scm", "clojure", "fennel", "janet", "lisp", "python", "lua" } 259 }, 260 --{ "hiphish/rainbow-delimiters.nvim", priority = 1050, }, 261 -- Conjure, lisp is magical 262 { 263 "Olical/conjure", 264 dependencies = { "PaterJason/cmp-conjure" }, 265 config = function() 266 vim.g["conjure#client#scheme#stdio#command"] = "gxi" 267 vim.g["conjure#client#scheme#stdio#prompt_pattern"] = "%d*> $?" 268 end, 269 lazy = true, 270 ft = { "scheme", "scm", "lisp", "fennel", "clojure", "lua", "janet" }, 271 }, 272 { "PaterJason/cmp-conjure", lazy = true }, 273 { "p1xelHer0/gerbil.nvim", lazy = true, ft = "scheme", config = true }, -- Fennel, Luasthp 274 { "jaawerth/fennel.vim", lazy = true, ft = "fennel", config = true }, 275 { "rktjmp/hotpot.nvim", lazy = true, ft = "fennel", config = true }, 276 { "Olical/nfnl", lazy = true, ft = "fennel", config = true }, -- Rust stuff 277 { 278 "simrat39/rust-tools.nvim", 279 lazy = true, 280 ft = { "rust" }, 281 config = function() 282 local rt = require("rust-tools") 283 rt.setup({ 284 server = { 285 on_attach = function(_, bufnr) 286 -- Hover actions 287 vim.keymap.set("n", "<C-space>", 288 rt.hover_actions.hover_actions, 289 { buffer = bufnr }) 290 -- Code action groups 291 vim.keymap.set("n", "<Leader>a", 292 rt.code_action_group.code_action_group, 293 { buffer = bufnr }) 294 end 295 } 296 }) 297 end, 298 dependencies = { "nvim-lua/plenary.nvim" } 299 }, 300 { "mfussenegger/nvim-dap", lazy = true, ft = { "c", "rust" } }, 301 { 302 "saecki/crates.nvim", 303 tag = "v0.4.0", 304 dependencies = { "nvim-lua/plenary.nvim" }, 305 config = function() require("crates").setup() end, 306 lazy = true, 307 ft = { "rust" } 308 }, -- RISC-V Assembly syntax highlighting 309 { "kylelaker/riscv.vim", ft = "riscv" }, -- Hare Stuff 310 -- Hare stuff 311 -- Haredoc 312 { 313 url = "https://git.sr.ht/~torresjrjr/vim-haredoc", 314 lazy = true, 315 ft = { "hare" }, 316 branch = "dev" 317 }, 318 { url = "https://git.sr.ht/~sircmpwn/hare.vim", ft = { "hare" } }, 319 -- TCL 320 { "lewis6991/tree-sitter-tcl", lazy = true, build = "make" }, 321 -- LF 322 { 323 "ptzz/lf.vim", 324 lazy = true, 325 cmd = { "Lf" }, 326 dependencies = { "voldikss/vim-floaterm" } 327 }, 328 { "imsnif/kdl.vim", lazy = true, ft = "kdl" }, 329 { "catgoose/nvim-colorizer.lua", lazy = true, ft = { "css", "html", "toml", "conf" } }, 330 { "github/copilot.vim", lazy = true, cmd = { "Copilot" } } 331 } 332})