Compare commits

...

3 Commits

Author SHA1 Message Date
Amir Alexander Abdelbaki 50c5b72683 fix(nvim): auto-insert in terminal buffers, add terminal window nav
- BufEnter term://* auto-calls startinsert so alot/abook receive keys
  immediately without needing to press i/a first (skips floaterm)
- <C-hjkl> in terminal-insert mode exits to normal then moves window,
  matching the existing normal-mode nav mappings

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-26 13:35:31 +02:00
Amir Alexander Abdelbaki ddd632fb7e fix(alot): restore esc = exit in search mode, add / = refineprompt
esc closes the search buffer (exits alot only if it is the last buffer).
/ opens a prompt pre-filled with the current query for regex refinement.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-26 13:31:22 +02:00
Amir Alexander Abdelbaki 050d91d544 fix(alot): remove esc = exit from search mode
In the inbox/search view, exit has nowhere to go back to so it quit
alot entirely. Esc is now only bound in thread/taglist/bufferlist where
it navigates back without closing the application.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-26 13:25:44 +02:00
2 changed files with 18 additions and 1 deletions

View File

@ -9,6 +9,7 @@
[bindings]
[[search]]
esc = exit
/ = refineprompt
[[thread]]
esc = exit
[[taglist]]

View File

@ -87,12 +87,28 @@ vim.opt.wildmenu = true
vim.opt.wildmode = "list:longest"
-- ── Keymaps ───────────────────────────────────────────────────────────────────
-- window navigation
-- window navigation (normal mode)
vim.keymap.set("n", "<C-l>", "<C-w>w")
vim.keymap.set("n", "<C-h>", "<C-w>h")
vim.keymap.set("n", "<C-j>", "<C-w>j")
vim.keymap.set("n", "<C-k>", "<C-w>k")
-- window navigation from terminal-insert mode (exit insert, then move)
vim.keymap.set("t", "<C-h>", "<C-\\><C-n><C-w>h", { silent = true })
vim.keymap.set("t", "<C-j>", "<C-\\><C-n><C-w>j", { silent = true })
vim.keymap.set("t", "<C-k>", "<C-\\><C-n><C-w>k", { silent = true })
vim.keymap.set("t", "<C-l>", "<C-\\><C-n><C-w>w", { silent = true })
-- auto-enter insert mode when focusing a terminal buffer (skip floaterm)
vim.api.nvim_create_autocmd("BufEnter", {
pattern = "term://*",
callback = function()
if vim.bo.filetype ~= "floaterm" then
vim.cmd("startinsert")
end
end,
})
-- calendar.vim steals <C-hjkl> for month nav; restore window movement
vim.api.nvim_create_autocmd("FileType", {
pattern = "calendar",