From 9635b45404201eab5965a790e1c93fd4762d967f Mon Sep 17 00:00:00 2001 From: siduck76 Date: Wed, 25 Aug 2021 20:13:47 +0530 Subject: [PATCH] clean mappings conf --- lua/core/mappings.lua | 18 +++++------------- 1 file changed, 5 insertions(+), 13 deletions(-) diff --git a/lua/core/mappings.lua b/lua/core/mappings.lua index b430da5..cee78d8 100644 --- a/lua/core/mappings.lua +++ b/lua/core/mappings.lua @@ -56,8 +56,7 @@ M.misc = function() map( "n", maps.theme_toggler, - ":lua require('nvchad').toggle_theme(require('core.utils').load_config().ui.theme_toggler.fav_themes) ", - opt + ":lua require('nvchad').toggle_theme(require('core.utils').load_config().ui.theme_toggler.fav_themes) " ) end end @@ -80,12 +79,7 @@ M.misc = function() map("n", term_maps.pick_term, ":Telescope terms ") -- Open terminals -- TODO this opens on top of an existing vert/hori term, fixme - map( - "n", - term_maps.new_horizontal, - ":execute 15 .. 'new +terminal' | let b:term_type = 'hori' | startinsert ", - opt - ) + map("n", term_maps.new_horizontal, ":execute 15 .. 'new +terminal' | let b:term_type = 'hori' | startinsert ") map("n", term_maps.new_vertical, ":execute 'vnew +terminal' | let b:term_type = 'vert' | startinsert ") map("n", term_maps.new_window, ":execute 'terminal' | let b:term_type = 'wind' | startinsert ") -- terminal mappings end -- @@ -104,7 +98,6 @@ M.misc = function() -- add ChadReload command and maping cmd "silent! command! NvChadReload lua require('chad_reload').Restart()" - end local function user_config_mappings() @@ -144,8 +137,7 @@ M.chadsheet = function() map( "n", m.user_keys, - ":lua require('cheatsheet').show_cheatsheet_telescope{bundled_cheatsheets = false, bundled_plugin_cheatsheets = false } ", - opt + ":lua require('cheatsheet').show_cheatsheet_telescope{bundled_cheatsheets = false, bundled_plugin_cheatsheets = false } " ) end @@ -167,7 +159,7 @@ end M.nvimtree = function() map("n", plugin_maps.nvimtree.toggle, ":NvimTreeToggle ") - map("n", plugin_maps.nvimtree.focus, ":NvimTreeFocus ") + map("n", plugin_maps.nvimtree.focus, ":NvimTreeFocus ") end M.neoformat = function() @@ -179,7 +171,7 @@ M.telescope = function() map("n", m.buffers, ":Telescope buffers ") map("n", m.find_files, ":Telescope find_files ") - map("n", m.find_hiddenfiles, ":Telescope find_files hidden=true ", opt) + map("n", m.find_hiddenfiles, ":Telescope find_files hidden=true ") map("n", m.git_commits, ":Telescope git_commits ") map("n", m.git_status, ":Telescope git_status ") map("n", m.help_tags, ":Telescope help_tags ")