From 09fd7f0294f975f53f72bc3551099f968341419e Mon Sep 17 00:00:00 2001 From: Igor Soarez Date: Mon, 5 Oct 2026 16:20:06 +0300 Subject: Caps Lock no longer types into Neovim Caps Lock sends F20, and the terminal passes it on as well as Wispr Flow seeing it. tmux reads it as S-F10 and hands the pane ESC[21;2~, which Neovim decodes as and, with nothing mapped to it, types out as text -- once per repeat while the key is held. Dropped in both places, each enough alone: Neovim maps and to nothing, terminal mode included so a :terminal does not pass it to its shell, and tmux binds S-F10 to an empty command, which also swallows a real Shift+F10 that nothing here uses. The empty binding loads on tmux 3.5a and 3.4. From change request cee596. --- config/nvim/init.lua | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'config/nvim') diff --git a/config/nvim/init.lua b/config/nvim/init.lua index 3f094e8..89ab1b8 100644 --- a/config/nvim/init.lua +++ b/config/nvim/init.lua @@ -241,6 +241,19 @@ if not vim.g.lazy_bootstrapped then require("config.lazy") end +------------------------------------------------------ +---- Caps Lock key ----------------------------------- +------------------------------------------------------ + +-- Caps Lock sends F20 (hammerspoon), which reaches Neovim as F22 through tmux. +-- Neovim types the name of a function key nothing maps, so holding it filled +-- the buffer with . Wispr Flow reads the key before the terminal does, so +-- nothing is lost by dropping it here. Terminal mode too, or holding it in a +-- :terminal would send the key on to the shell running there. +for _, key in ipairs({ "", "" }) do + vim.keymap.set({ "n", "x", "s", "o", "i", "c", "t" }, key, "") +end + ------------------------------------------------------ ---- Terminal ---------------------------------------- ------------------------------------------------------ -- cgit v1.2.3