From 9e72f022ca58b6123aed8ccfdd60611743fcddf1 Mon Sep 17 00:00:00 2001 From: Andreas Wachs Date: Fri, 7 Jul 2023 07:42:17 +0200 Subject: [PATCH] Import toggleterm --- lua/custom/plugins/toggleterm.lua | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 lua/custom/plugins/toggleterm.lua diff --git a/lua/custom/plugins/toggleterm.lua b/lua/custom/plugins/toggleterm.lua new file mode 100644 index 00000000..827b43de --- /dev/null +++ b/lua/custom/plugins/toggleterm.lua @@ -0,0 +1,28 @@ +local Terminal = require('toggleterm.terminal').Terminal +local lazygit = Terminal:new({ cmd = "lazygit", hidden = true }) + +function _lazygit_toggle() + lazygit:toggle() +end + +return { + { + "akinsho/toggleterm.nvim", + event = "VeryLazy", + cmd = { "ToggleTerm", "TermExec" }, + opts = { + size = 10, + on_create = function() + vim.opt.foldcolumn = "0" + vim.opt.signcolumn = "no" + end, + open_mapping = [[]], + shading_factor = 2, + direction = "float", + float_opts = { + border = "curved", + highlights = { border = "Normal", background = "Normal" }, + }, + }, + }, +}