2024-04-20 13:42:06 +00:00
|
|
|
{
|
|
|
|
pkgs,
|
|
|
|
dsl,
|
|
|
|
config,
|
|
|
|
...
|
|
|
|
}:
|
|
|
|
{
|
2022-11-28 05:37:47 +00:00
|
|
|
|
2023-07-31 00:26:23 +00:00
|
|
|
# Toggleterm provides a floating terminal inside the editor for quick access
|
|
|
|
|
2022-11-28 05:37:47 +00:00
|
|
|
plugins = [ pkgs.vimPlugins.toggleterm-nvim ];
|
|
|
|
|
|
|
|
use.toggleterm.setup = dsl.callWith {
|
|
|
|
open_mapping = dsl.rawLua "[[<c-\\>]]";
|
|
|
|
hide_numbers = true;
|
|
|
|
direction = "float";
|
2024-06-12 11:07:47 +00:00
|
|
|
float_opts = {
|
|
|
|
width = dsl.rawLua "vim.o.columns - 4";
|
|
|
|
height = dsl.rawLua "vim.o.lines - 4";
|
|
|
|
row = 0;
|
|
|
|
};
|
2022-11-28 05:37:47 +00:00
|
|
|
};
|
|
|
|
|
2023-11-06 01:40:18 +00:00
|
|
|
lua = ''
|
|
|
|
${builtins.readFile ./toggleterm.lua}
|
|
|
|
${if config.github then (builtins.readFile ./github.lua) else ""}
|
|
|
|
${if config.kubernetes then (builtins.readFile ./kubernetes.lua) else ""}
|
|
|
|
'';
|
2022-11-28 05:37:47 +00:00
|
|
|
}
|