summaryrefslogtreecommitdiff
path: root/.config/nvim/lua/plugins/iswap.lua
diff options
context:
space:
mode:
authorKyren223 <Kyren223@proton.me>2025-05-07 20:05:04 +0300
committerKyren223 <Kyren223@proton.me>2025-05-07 20:05:04 +0300
commitffaf12680fd5e97fe09ec4f5bb2acf441b1b8d0f (patch)
treea5293b44fbab07c8fb80efdf449bffa68c090890 /.config/nvim/lua/plugins/iswap.lua
parent1f99b3c587814ad887695c8d72226248d2953696 (diff)
Replaced treewalker with iswap which works better (like keeping
whitespace for cases like switch statements)
Diffstat (limited to '.config/nvim/lua/plugins/iswap.lua')
-rw-r--r--.config/nvim/lua/plugins/iswap.lua17
1 files changed, 17 insertions, 0 deletions
diff --git a/.config/nvim/lua/plugins/iswap.lua b/.config/nvim/lua/plugins/iswap.lua
new file mode 100644
index 0000000..2de3b7a
--- /dev/null
+++ b/.config/nvim/lua/plugins/iswap.lua
@@ -0,0 +1,17 @@
+return {
+ 'mizlan/iswap.nvim',
+ event = 'VeryLazy',
+ keys = {
+ { 'H', '<cmd>IMoveNodeWithLeft<cr>', silent = true },
+ { 'L', '<cmd>IMoveNodeWithRight<cr>', silent = true },
+ },
+ opts = {
+ -- Post-operation flashing highlight style,
+ -- either 'simultaneous' or 'sequential', or false to disable
+ -- default 'sequential'
+ flash_style = false,
+
+ -- Move cursor to the other element in ISwap*With commands
+ move_cursor = true,
+ },
+}