.dotfiles/.config/qutebrowser/keybindings.py

35 lines
1.5 KiB
Python
Raw Normal View History

def init(c):
c.bind(',v', 'spawn --userscript view_in_mpv {url}')
c.bind(',V', 'hint links spawn --userscript view_in_mpv {hint-url}')
2021-05-13 12:26:52 +00:00
# ungoogled-chromium
c.bind(',b', 'spawn chromium {url}')
c.bind(',B', 'hint links spawn chromium {hint-url}')
c.bind(',j', 'spawn --userscript format_json')
c.bind(',g', 'open {url:scheme}://github1s.com{url:path}{url:query}')
c.bind(',rr', 'open {url:scheme}://removeddit.com{url:path}{url:query}')
c.bind(',rt', 'open {url:scheme}://reddit.tube{url:path}{url:query}')
c.bind(',s', 'spawn steam steam://openurl/{url}')
2021-12-21 11:13:11 +00:00
gpg_key = '723B78C0BF8D8C721D2C4EEF41E544A54E2533B2'
#c.bind(',Pp', 'spawn --userscript qute-keepassxc --key ABC1234', mode='insert')
c.bind(',p', 'spawn --userscript qute-keepassxc --key ' + gpg_key, mode='normal')
c.bind(',Po', 'spawn --userscript qute-keepassxc --otp --key ' + gpg_key, mode='normal')
#pass_script_default = 'spawn --userscript qute-pass --no-insert-mode --username-target secret --username-pattern "login: (.+)" '
#c.bind(',p', pass_script_default)
#c.bind(',Pu', pass_script_default + '--username-only')
#c.bind(',Pi', pass_script_default + '--password-only')
#c.bind(',Po', pass_script_default + '--otp-only')
c.bind(',q', 'spawn --userscript qr {url}')
c.bind(',Q', 'hint links spawn --userscript qr {hint-url}')
c.bind('<Alt-9>', 'tab-focus 9')
c.bind('<Ctrl-Tab>', 'tab-next')
c.bind('<Ctrl-Shift-Tab>', 'tab-prev')