]> git.rmz.io Git - dotfiles.git/blobdiff - nvim/lua/plugins/editor.lua
nvim: use nvim-origami for folds
[dotfiles.git] / nvim / lua / plugins / editor.lua
index 1e94ab0bc0a7b6e0362f71a349e54fc82e045d7c..249ac6d16f9745bcf2375f29585af5da5e2b7ae9 100644 (file)
@@ -83,7 +83,7 @@ return {
     },
     opts = {}
   },
-  { "echasnovski/mini.hipatterns",  -- highlight hex colours and other matched words
+  { "nvim-mini/mini.hipatterns",  -- highlight hex colours and other matched words
     event = { "BufReadPost", "BufNewFile", "BufWritePre" },
     opts = function()
       local hi = require("mini.hipatterns")
@@ -94,6 +94,9 @@ return {
       }
     end,
   },
+  { "nvim-mini/mini.operators",  -- text edit operators
+    opts = {},
+  },
   { "folke/flash.nvim",
     -- Flash enhances the built-in search functionality by showing labels
     -- at the end of each match, letting you quickly jump to a specific
@@ -179,6 +182,23 @@ return {
       end,
     },
   },
+  { "chrisgrieser/nvim-origami", -- fold with elegance
+    event = "VeryLazy",
+    opts = {
+      foldKeymaps = { setup = false },
+      foldtext = {
+        padding = 1,
+        lineCount = {
+          template = "…  %d lines"
+        }
+      }
+    },
+    init = function()
+      -- disable vim's folding
+      vim.opt.foldlevel = 99
+      vim.opt.foldlevelstart = 99
+    end
+  },
 
   -- TODO: currently unused plugins, check and enable/remove
   { "MagicDuck/grug-far.nvim", enabled = false,
@@ -203,7 +223,4 @@ return {
       },
     },
   },
-  { "aymericbeaumet/vim-symlink",
-    dependencies = { "moll/vim-bbye" }, -- NOTE: Snacks.buddelete also provides this
-  },
 }