diff options
Diffstat (limited to 'after/plugin/toggleterm.lua')
-rw-r--r-- | after/plugin/toggleterm.lua | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/after/plugin/toggleterm.lua b/after/plugin/toggleterm.lua new file mode 100644 index 0000000..b0cd2c8 --- /dev/null +++ b/after/plugin/toggleterm.lua @@ -0,0 +1,33 @@ +local status_ok, toggleterm = pcall(require, "toggleterm") +if not status_ok then + return +end + +toggleterm.setup { + shade_terminals = true, + float_opts = { + border = 'shadow', + }, + on_open = function() + vim.opt.cmdheight = 0 + end, + on_close = function() + vim.opt.cmdheight = 1 + end +} + +local term = require('toggleterm.terminal').Terminal +local glow = term:new({ + cmd = "glow", + hidden = true, + direction = "float", + float_opts = { + border = "shadow", + width = 120, + height = 50, + } +}) + +function _glow() + glow:toggle() +end |