gh watch keybind for neovim toggleterm

This commit is contained in:
Noah Masur 2024-06-05 13:54:09 -04:00
parent e55ee05c5c
commit 8b1032ebda
No known key found for this signature in database

View File

@ -2,8 +2,11 @@
vim.keymap.set("n", "<Leader>gr", ":!gh browse %<CR><CR>", { silent = true })
-- Pop a terminal to watch the current run
local gitwatch =
require("toggleterm.terminal").Terminal:new({ cmd = "fish --interactive --init-command 'gh run watch'" })
local gitwatch = require("toggleterm.terminal").Terminal:new({
cmd = "fish --interactive --init-command 'gh run watch'",
hidden = true,
direction = "float",
})
-- Set a toggle for this terminal
function GITWATCH_TOGGLE()
@ -11,4 +14,4 @@ function GITWATCH_TOGGLE()
end
-- Keymap to toggle the run
vim.keymap.set("n", "<Leader>gw", GITWATCH_TOGGLE)
vim.keymap.set("n", "<Leader>W", GITWATCH_TOGGLE)