summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdam <56338480+adastx@users.noreply.github.com>2021-10-10 10:34:22 +0200
committerAdam <56338480+adastx@users.noreply.github.com>2021-10-10 10:37:21 +0200
commitf8ce0f7d8cc352503c2fcab3e63349243880b976 (patch)
tree549a2e4363dbb4a4042cf4a28b03606a3dd3b425
parent0800a24c80f6dc1e3a3891e8796df2321a204493 (diff)
vim added keybind to toggle show/hide terminal
-rw-r--r--.config/nvim/lua/opts.lua10
-rw-r--r--.config/nvim/lua/plugins.lua1
2 files changed, 11 insertions, 0 deletions
diff --git a/.config/nvim/lua/opts.lua b/.config/nvim/lua/opts.lua
index a22a538..184900a 100644
--- a/.config/nvim/lua/opts.lua
+++ b/.config/nvim/lua/opts.lua
@@ -109,6 +109,16 @@ require'nvim-treesitter.configs'.setup {
},
}
+require("toggleterm").setup{
+ -- size can be a number or function which is passed the current terminal
+ size = 75,
+ open_mapping = [[<c-\>]],
+ hide_numbers = true, -- hide the number column in toggleterm buffers
+ persist_size = true,
+ direction = 'vertical',
+ close_on_exit = true, -- close the terminal window when the process exits
+}
+
-- Misc
require('kommentary.config').use_extended_mappings()
vim.o.tabline = '%!v:lua.require\'luatab\'.tabline()'
diff --git a/.config/nvim/lua/plugins.lua b/.config/nvim/lua/plugins.lua
index 3ae9343..e230423 100644
--- a/.config/nvim/lua/plugins.lua
+++ b/.config/nvim/lua/plugins.lua
@@ -15,6 +15,7 @@ require('packer').startup(function()
use 'norcalli/nvim-colorizer.lua'
use 'b3nj5m1n/kommentary'
use 'mhinz/vim-startify'
+ use "akinsho/toggleterm.nvim"
use {
'nvim-telescope/telescope.nvim',