Created
October 17, 2022 02:53
-
-
Save thepeopleseason/da275f076f01ac1248801b4e1af7dc89 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
local rep = hs.hotkey.modal.new(hyper, 'a', "keyRepeat mode") | |
function rep:entered() keyRepeat = false end | |
rep:bind(nil, "escape", function() rep:exit() hs.alert'Exited keyRepeat mode' end) | |
rep:bind(nil, | |
"r", | |
function() hs.timer.doUntil( | |
function() return keyRepeat end, | |
function() hs.eventtap.keyStroke(nil, "x") end, | |
0.002) | |
end) | |
rep:bind(nil, 's', function() keyRepeat = true rep:exit() end) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment