blob: cfc9a33ac8ba75f700666c8637cd8245a68ae5e8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
;; Terminal inside nvim.
(module config.toggleterm
{autoload {: util nvim aniseed.nvim autocmd config.autocmd}})
(def- opts {:shade_terminals false})
(defn- set-terminal-keymaps []
(nvim.set_keymap :t :<C-h> "<Cmd>wincmd h<CR>" {})
(nvim.set_keymap :t :<C-j> "<Cmd>wincmd j<CR>" {})
(nvim.set_keymap :t :<C-k> "<Cmd>wincmd k<CR>" {})
(nvim.set_keymap :t :<C-l> "<Cmd>wincmd l<CR>" {}))
(util.use-config :toggleterm opts)
(autocmd.create-autocmd :TermOpen
{:pattern "term://*toggleterm#*"
:callback set-terminal-keymaps})
|