🪴 my neovim config:)
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

init: use lynn to lazy load config

robin 23eb96a2 3f23c9ea

+77 -75
+6
config/lua/ivy/config/ft.lua config/plugin/treesitter.lua
··· 1 + if vim.g.ivy_ft then 2 + return 3 + end 4 + 5 + vim.g.ivy_ft = true 6 + 1 7 vim.filetype.add({ 2 8 extension = { 3 9 jq = "jq",
+29 -34
config/lua/ivy/init.lua
··· 2 2 require("ivy.once") 3 3 require("ivy.notifs").init() 4 4 5 - local config_base = "ivy.config" 6 - 7 - local load_cfg = function(name) 8 - local mod = config_base .. "." .. name 5 + local load_cfg = function(mod) 9 6 local ok, result = pcall(require, mod) 10 7 if not ok then 11 8 return vim.notify("error loading " .. mod .. ":\n\t" .. result, vim.log.levels.ERROR) ··· 13 10 return result 14 11 end 15 12 13 + local load = function(spec) 14 + return load_cfg(spec.name) 15 + end 16 + 17 + local base_path = debug.getinfo(1).source:sub(2, -#"/lua/ivy/init.lua") 18 + 16 19 vim 17 20 .iter(ipairs({ 18 - { "disable" }, 19 - { "options" }, 20 - { "autocmds", event = "ConfigDone" }, 21 - { "cmds", event = "VimEnter" }, 22 - { "ft", event = "ConfigDone" }, 23 - { "keybinds", event = "UIEnter" }, 24 - { "neovide" }, 25 - { "lsp", event = "ConfigDone" }, 21 + { "ivy.config.disable" }, 22 + { "ivy.config.options" }, 23 + { "ivy.config.autocmds", event = "User ConfigDone" }, 24 + { "ivy.config.cmds", event = "VimEnter" }, 25 + { "ivy.config.keybinds", event = "UIEnter" }, 26 + { "ivy.config.neovide" }, 27 + { "ivy.config.lsp", event = "User PackDone" }, 26 28 })) 27 - :each(function(_, opts) 28 - local name = opts[1] 29 - if not name then 30 - return 31 - end 32 - ---@type string? 33 - local pattern 34 - if opts.event then 35 - if opts.event == "ConfigDone" then 36 - opts.event = "User" 37 - pattern = "ConfigDone" 38 - end 39 - vim.on(opts.event, pattern, { 40 - group = vim.api.nvim_create_augroup("ivy:" .. vim.inspect(opts.event) .. "[" .. name .. "]", { clear = true }), 41 - once = true, 42 - }, function() 43 - load_cfg(name) 44 - end) 45 - return 46 - end 47 - load_cfg(name) 29 + :map(function(_, spec) 30 + local modname = spec[1] 31 + local path = vim.fs.joinpath(base_path, ("lua/%s.lua"):format(modname:gsub("%.", "/"))) 32 + return { 33 + name = spec[1], 34 + url = "file://" .. path, 35 + event = spec.event, 36 + path = path, 37 + load = load, 38 + } 39 + end) 40 + :each(function(plug) 41 + require("lynn").register(plug, true) 42 + require("lynn").load(plug.name) 48 43 end) 49 44 50 45 require("lynn").packdir = vim.fs.joinpath( ··· 59 54 local name = string.gsub(vim.fs.basename(file), "%.lua$", "") 60 55 require("lynn").import("ivy.plugins." .. name, true) 61 56 end) 62 - require("lynn").loadall() 57 + require("lynn").setup() 63 58 64 59 vim.api.nvim_exec_autocmds("User", { pattern = "ConfigDone" }) 65 60
+2 -2
config/lua/ivy/plugins/code-snips.lua
··· 2 2 { 3 3 "freeze.nvim", 4 4 event = "BufReadPost", 5 - after = function() 5 + config = function() 6 6 vim.keymap.set("v", "<leader>sc", "<cmd>Freeze<cr>") 7 7 8 8 require("freeze").setup({ ··· 19 19 { 20 20 "sayama.nvim", 21 21 event = "BufReadPost", 22 - after = function() 22 + config = function() 23 23 require("sayama").setup({ 24 24 dir = vim.fn.glob("$XDG_DATA_HOME/zzz"), 25 25 })
+18 -18
config/lua/ivy/plugins/init.lua
··· 78 78 { 79 79 "windsurf.nvim", 80 80 name = "windsurf.nvim", 81 - after = function() 81 + config = function() 82 82 require("codeium").setup({ 83 83 enable_cmp_source = false, 84 84 }) ··· 90 90 "keymaps.nvim", 91 91 lazy = false, 92 92 priority = 1000, 93 - after = function() 93 + config = function() 94 94 require("keymaps").setup() 95 95 end, 96 96 }, ··· 109 109 { 110 110 "mini.ai", 111 111 event = "BufAdd", 112 - after = function() 112 + config = function() 113 113 require("mini.ai").setup({ 114 114 mappings = { 115 115 -- Main textobject prefixes ··· 132 132 { 133 133 "mini.align", 134 134 event = "BufAdd", 135 - after = function() 135 + config = function() 136 136 require("mini.align").setup() 137 137 end, 138 138 }, 139 139 { 140 140 "mini.bracketed", 141 141 event = "UIEnter", 142 - after = function() 142 + config = function() 143 143 require("mini.bracketed").setup() 144 144 end, 145 145 }, 146 146 { 147 147 "mini.diff", 148 148 event = "BufAdd", 149 - after = function() 149 + config = function() 150 150 require("mini.diff").setup({ 151 151 view = { 152 152 style = "number", ··· 187 187 { 188 188 "mini.files", 189 189 event = "UIEnter", 190 - after = function() 190 + config = function() 191 191 require("mini.files").setup({ 192 192 options = { 193 193 use_as_default_explorer = false, ··· 217 217 { 218 218 "mini-git", 219 219 event = "UIEnter", 220 - after = function() 220 + config = function() 221 221 require("mini.git").setup() 222 222 end, 223 223 }, ··· 225 225 "mini.icons", 226 226 lazy = false, 227 227 priority = 1000, 228 - after = function() 228 + config = function() 229 229 require("mini.icons").setup({ 230 230 filetype = { 231 231 qmljs = { glyph = "󰫾", hl = "MiniIconsAzure" }, ··· 278 278 { 279 279 "mini.jump2d", 280 280 event = "BufAdd", 281 - after = function() 281 + config = function() 282 282 require("mini.jump2d").setup({ 283 283 view = { 284 284 dim = true, ··· 289 289 { 290 290 "mini.move", 291 291 event = "BufAdd", 292 - after = function() 292 + config = function() 293 293 require("mini.move").setup({ 294 294 mappings = { 295 295 -- Move visual selection in Visual mode. Defaults are Alt (Meta) + hjkl. ··· 316 316 { 317 317 "mini.operators", 318 318 event = "BufAdd", 319 - after = function() 319 + config = function() 320 320 require("mini.operators").setup({ 321 321 exchange = { prefix = "Cx" }, 322 322 multiply = { prefix = "Cm" }, ··· 328 328 { 329 329 "mini.pairs", 330 330 event = "InsertEnter", 331 - after = function() 331 + config = function() 332 332 require("mini.pairs").setup() 333 333 end, 334 334 }, 335 335 { 336 336 "mini.splitjoin", 337 337 event = "BufAdd", 338 - after = function() 338 + config = function() 339 339 require("mini.splitjoin").setup() 340 340 end, 341 341 }, 342 342 { 343 343 "mini.surround", 344 344 event = "InsertEnter", 345 - after = function() 345 + config = function() 346 346 require("mini.surround").setup({ 347 347 mappings = { 348 348 add = "S", -- Add surrounding in Normal and Visual modes ··· 361 361 { 362 362 "mini.trailspace", 363 363 event = "BufAdd", 364 - after = function() 364 + config = function() 365 365 require("mini.trailspace").setup({ 366 366 -- highlight only in normal buffers (ones with empty 'buftype'). this is 367 367 -- useful to not show trailing whitespace where it usually doesn't matter. ··· 375 375 enabled = function() 376 376 return vim.fn.executable("direnv") == 1 377 377 end, 378 - after = function() 378 + config = function() 379 379 require("direnv").setup({ 380 380 autoload_direnv = true, 381 381 }) ··· 396 396 "cord.nvim", 397 397 name = "cord.nvim", 398 398 lazy = false, 399 - after = function() 399 + config = function() 400 400 require("cord").setup({ 401 401 editor = { 402 402 tooltip = "the modal text editor of your nightmares",
+2 -2
config/lua/ivy/plugins/lsp.lua
··· 3 3 4 4 { 5 5 "crates.nvim", 6 - after = function() 6 + config = function() 7 7 require("crates").setup({}) 8 8 end, 9 9 event = "BufRead Cargo.toml", ··· 16 16 { 17 17 "symbol-usage.nvim", 18 18 event = "BufReadPost", 19 - after = function() 19 + config = function() 20 20 local SymbolKind = vim.lsp.protocol.SymbolKind 21 21 22 22 ---@diagnostic disable-next-line: missing-fields
+3 -3
config/lua/ivy/plugins/tree-sitter.lua
··· 2 2 { 3 3 "nvim-treesitter-context", 4 4 event = "UIEnter", 5 - after = function() 5 + config = function() 6 6 local exclude_filetypes = { "nix" } 7 7 8 8 require("treesitter-context").setup({ ··· 26 26 { 27 27 "neogen", 28 28 event = "BufAdd", 29 - after = function() 29 + config = function() 30 30 require("neogen").setup({}) 31 31 32 32 local function cbcall(fn, ...) ··· 58 58 { 59 59 "treewalker.nvim", 60 60 event = "BufAdd", 61 - after = function() 61 + config = function() 62 62 require("treewalker").setup({ 63 63 -- briefly highlight the node after jumping to it 64 64 highlight = true,
+6 -7
pkgs/ivy-plugins/_sources/generated.json
··· 322 322 }, 323 323 "lynn-nvim": { 324 324 "cargoLocks": null, 325 - "date": "2025-11-04", 325 + "date": "2025-12-22", 326 326 "extract": null, 327 327 "name": "lynn-nvim", 328 328 "passthru": { ··· 335 335 "fetchSubmodules": false, 336 336 "leaveDotGit": false, 337 337 "name": null, 338 - "owner": "comfysage", 339 - "repo": "lynn.nvim", 340 - "rev": "695536b501b873806a7e6f04697e9c6452de91b4", 341 - "sha256": "sha256-Ox1kZxlSpN+XHyfXqY7Lzu5BY/S6ZWU/3lJW2/EvMyo=", 338 + "rev": "d6cd8b3b71a90c9276406c883e026d0578f60cae", 339 + "sha256": "sha256-kaMyz6CKEv6Z4B8Y4OKcmQsIuF6fMVtPpKi874Eg0wc=", 342 340 "sparseCheckout": [], 343 - "type": "github" 341 + "type": "git", 342 + "url": "https://codeberg.org/comfysage/lynn.nvim" 344 343 }, 345 - "version": "695536b501b873806a7e6f04697e9c6452de91b4" 344 + "version": "d6cd8b3b71a90c9276406c883e026d0578f60cae" 346 345 }, 347 346 "marks-nvim": { 348 347 "cargoLocks": null,
+9 -7
pkgs/ivy-plugins/_sources/generated.nix
··· 185 185 }; 186 186 lynn-nvim = { 187 187 pname = "lynn-nvim"; 188 - version = "695536b501b873806a7e6f04697e9c6452de91b4"; 189 - src = fetchFromGitHub { 190 - owner = "comfysage"; 191 - repo = "lynn.nvim"; 192 - rev = "695536b501b873806a7e6f04697e9c6452de91b4"; 188 + version = "d6cd8b3b71a90c9276406c883e026d0578f60cae"; 189 + src = fetchgit { 190 + url = "https://codeberg.org/comfysage/lynn.nvim"; 191 + rev = "d6cd8b3b71a90c9276406c883e026d0578f60cae"; 193 192 fetchSubmodules = false; 194 - sha256 = "sha256-Ox1kZxlSpN+XHyfXqY7Lzu5BY/S6ZWU/3lJW2/EvMyo="; 193 + deepClone = false; 194 + leaveDotGit = false; 195 + sparseCheckout = [ ]; 196 + sha256 = "sha256-kaMyz6CKEv6Z4B8Y4OKcmQsIuF6fMVtPpKi874Eg0wc="; 195 197 }; 196 198 as = "lynn"; 197 199 start = "true"; 198 - date = "2025-11-04"; 200 + date = "2025-12-22"; 199 201 }; 200 202 marks-nvim = { 201 203 pname = "marks-nvim";
+2 -2
pkgs/ivy-plugins/nvfetcher.toml
··· 70 70 passthru.as = "lylla" 71 71 72 72 [lynn-nvim] 73 - fetch.github = "comfysage/lynn.nvim" 74 - src.git = "https://github.com/comfysage/lynn.nvim" 73 + fetch.git = "https://codeberg.org/comfysage/lynn.nvim" 74 + src.git = "https://codeberg.org/comfysage/lynn.nvim" 75 75 passthru.start = "true" 76 76 passthru.as = "lynn" 77 77