From 0260a43f53d987f3276520371cfde92aa3c805a9 Mon Sep 17 00:00:00 2001 From: brainfucksec Date: Sat, 25 Jun 2022 11:14:49 +0200 Subject: [PATCH] Update /lua/core/keymaps.lua (pastetoggle) --- nvim/init.lua | 2 +- nvim/lua/core/keymaps.lua | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/nvim/init.lua b/nvim/init.lua index dedb8c5..f507128 100644 --- a/nvim/init.lua +++ b/nvim/init.lua @@ -1,7 +1,7 @@ --[[ Neovim init file -Version: 0.62.0 - 2022/06/07 +Version: 0.63.0 - 2022/06/25 Maintainer: brainf+ck Website: https://github.com/brainfucksec/neovim-lua diff --git a/nvim/lua/core/keymaps.lua b/nvim/lua/core/keymaps.lua index 700289a..ba16ab3 100644 --- a/nvim/lua/core/keymaps.lua +++ b/nvim/lua/core/keymaps.lua @@ -29,6 +29,10 @@ map('i', 'kk', '') -- Clear search highlighting with and c map('n', 'c', ':nohl') +-- Toggle auto-indenting for code paste +map('n', '', ':set invpaste paste?') +vim.opt.pastetoggle = '' + -- Change split orientation map('n', 'tk', 'tK') -- change vertical to horizontal map('n', 'th', 'tH') -- change horizontal to vertical