diff --git a/init.lua b/init.lua index dca9449..56d5b2f 100644 --- a/init.lua +++ b/init.lua @@ -67,6 +67,12 @@ vim.keymap.set('n', 'q', vim.diagnostic.setloclist, { desc = 'Open diagn vim.keymap.set('t', '', '', { desc = 'Exit terminal mode' }) + +-- run clear and make in open terminal +vim.keymap.set('n','r','TermExec cmd="clear && make"', { desc = '[r]un make in terminal' }) +vim.keymap.set('n','n', 'ToggleTerm direction=vertical name=compile size=70', { desc = 'open a [n]ew terminal' }) +vim.keymap.set('n','t', 'ToggleTerm', {desc = '[T]oggle all terminals'}) + -- TIP: Disable arrow keys in normal mode vim.keymap.set('n', '', 'echo "Use h to move!!"') vim.keymap.set('n', '', 'echo "Use l to move!!"') diff --git a/lua/plugins/simple.lua b/lua/plugins/simple.lua index a768d83..d44d0dc 100644 --- a/lua/plugins/simple.lua +++ b/lua/plugins/simple.lua @@ -11,7 +11,6 @@ return { 'nvim-tree/nvim-web-devicons', -- nerdfont! 'nvim-lualine/lualine.nvim', -- lualine 'TamaMcGlinn/vim-termhere', --simple terminal QOL - { "denialofsandwich/sudo.nvim", dependencies = { "MunifTanjim/nui.nvim", - },config = true, - } + { "denialofsandwich/sudo.nvim", dependencies = { "MunifTanjim/nui.nvim", },config = true, }, + {'akinsho/toggleterm.nvim', version = "*", config = true} }