From 9b4ead61b5b21e98d16a75b3e0ac411e8bb9f665 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Fri, 7 Apr 2023 00:11:36 +0200 Subject: added pantran configuration --- config/essentials/nvim/after/plugin/pantran.lua | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 config/essentials/nvim/after/plugin/pantran.lua diff --git a/config/essentials/nvim/after/plugin/pantran.lua b/config/essentials/nvim/after/plugin/pantran.lua new file mode 100644 index 0000000..a7aab19 --- /dev/null +++ b/config/essentials/nvim/after/plugin/pantran.lua @@ -0,0 +1,18 @@ +require("pantran").setup{ + controls = { + mappings = { + edit = { + n = { + ["j"] = "gj", + ["k"] = "gk", + } + } + } + } +} +local pantran = require('pantran') +local opts = {noremap = true, silent = true, expr = true} +vim.keymap.set("n", "tr", pantran.motion_translate, opts) + +vim.keymap.set("n", "trr", function() return pantran.motion_translate() .. "_" end, opts) +vim.keymap.set("x", "tr", pantran.motion_translate, opts) -- cgit v1.2.3