From 2a6c37ea2c06f8b7b6d423d07928a2c0c5a43eb7 Mon Sep 17 00:00:00 2001 From: tastytea Date: Thu, 11 Aug 2022 22:32:26 +0200 Subject: [PATCH] nvim: keymaps: scroll in visual mode, too --- .config/nvim/lua/my/keymaps.lua | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.config/nvim/lua/my/keymaps.lua b/.config/nvim/lua/my/keymaps.lua index 0a18c9f..48fe4fb 100644 --- a/.config/nvim/lua/my/keymaps.lua +++ b/.config/nvim/lua/my/keymaps.lua @@ -12,6 +12,9 @@ for key, cmd in pairs({ Left = 'bprevious', Right = 'bnext' }) do map('n', format('', key), format(':%s', cmd)) map('i', format('', key), format(':%s', cmd)) end +-- move buffer without moving cursor +map({ 'n', 'v' }, '', '') +map({ 'n', 'v' }, '', '') --windows for key, letter in pairs({ Left = 'h', Down = 'j', Up = 'k', Right = 'l' }) do @@ -50,10 +53,6 @@ map({ 'n', 'i' }, '', end ) --- move buffer without moving cursor -map('n', '', '') -map('n', '', '') - -- system clipboard map('v', 'y', '"+y') map('n', 'p', '"+p')