Dot_Files/.config/wezterm/config/keybinds.lua

71 lines
2.9 KiB
Lua
Raw Normal View History

2022-07-08 21:07:14 -05:00
local wezterm = require("wezterm")
2022-06-20 03:15:17 -05:00
return {
2022-07-08 21:07:14 -05:00
-- disable_default_key_bindings = true,
leader = { key = "a", mods = "CTRL", timeout_milliseconds = 100000 },
2022-06-20 03:15:17 -05:00
keys = {
2022-07-08 21:07:14 -05:00
{ key = "r", mods = "SUPER", action = "ReloadConfiguration" },
{ key = "z", mods = "SUPER", action = wezterm.action({ ActivateTabRelative = -1 }) },
{ key = "x", mods = "SUPER", action = wezterm.action({ ActivateTabRelative = 1 }) },
{ key = "t", mods = "SUPER", action = wezterm.action({ SpawnTab = "CurrentPaneDomain" }) },
{ key = "w", mods = "ALT", action = wezterm.action({ CloseCurrentPane = { confirm = false } }) },
{ key = "w", mods = "SUPER", action = wezterm.action({ CloseCurrentTab = { confirm = false } }) },
{ key = "c", mods = "SUPER", action = wezterm.action({ CopyTo = "Clipboard" }) },
{ key = "v", mods = "SUPER", action = wezterm.action({ PasteFrom = "Clipboard" }) },
-- NOTE: Pane Splitting
2022-06-20 03:15:17 -05:00
{
2022-07-08 21:07:14 -05:00
key = "RightArrow",
mods = "SHIFT",
action = wezterm.action({ SplitPane = { direction = "Right" } }),
2022-06-20 03:15:17 -05:00
},
{
2022-07-08 21:07:14 -05:00
key = "LeftArrow",
mods = "SHIFT",
action = wezterm.action({ SplitPane = { direction = "Left" } }),
2022-06-20 03:15:17 -05:00
},
{
2022-07-08 21:07:14 -05:00
key = "UpArrow",
mods = "SHIFT",
action = wezterm.action({ SplitPane = { direction = "Up" } }),
2022-06-20 03:15:17 -05:00
},
{
2022-07-08 21:07:14 -05:00
key = "DownArrow",
mods = "SHIFT",
action = wezterm.action({ SplitPane = { direction = "Down" } }),
2022-06-20 03:15:17 -05:00
},
-- NOTE: Pane Selecting
{
2022-07-08 21:07:14 -05:00
key = "RightArrow",
mods = "CTRL",
action = wezterm.action({ ActivatePaneDirection = "Right" }),
},
{
2022-07-08 21:07:14 -05:00
key = "LeftArrow",
mods = "CTRL",
action = wezterm.action({ ActivatePaneDirection = "Left" }),
},
{
2022-07-08 21:07:14 -05:00
key = "UpArrow",
mods = "CTRL",
action = wezterm.action({ ActivatePaneDirection = "Up" }),
},
{
2022-07-08 21:07:14 -05:00
key = "DownArrow",
mods = "CTRL",
action = wezterm.action({ ActivatePaneDirection = "Down" }),
},
2022-07-08 21:07:14 -05:00
{ key = "=", mods = "CTRL", action = "IncreaseFontSize" },
{ key = "-", mods = "CTRL", action = "DecreaseFontSize" },
{ key = "0", mods = "CTRL", action = "ResetFontAndWindowSize" },
-- NOTE: Leader dependent binds
{ key = "h", mods = "LEADER", action = wezterm.action({ EmitEvent = "trigger-nvim-with-scrollback" }) },
{ key = "f", mods = "LEADER", action = wezterm.action.ToggleFullScreen },
-- NOTE: Quick bindings for in termal use
{ key = "w", mods = "LEADER", action = { SendString = "wgrep\x0D" } },
{ key = "t", mods = "LEADER", action = { SendString = "fd --color=always | fzf\x0D" } },
2022-06-20 03:15:17 -05:00
},
2022-07-08 16:57:04 -05:00
key_tables = {},
2022-06-20 03:15:17 -05:00
}