feat(hammerspoon/noct): add Google Calendar, improve URL matching

This commit is contained in:
2023-12-18 10:55:49 +00:00
parent 08011c0fef
commit a5fc1a070a

View File

@@ -12,7 +12,7 @@ local function init_hotkeys()
apptoggle:bind({ 'cmd', 'ctrl' }, '4', { 'FastGPT' }) apptoggle:bind({ 'cmd', 'ctrl' }, '4', { 'FastGPT' })
apptoggle:bind({ 'cmd', 'ctrl' }, 'A', { 'Messages' }) apptoggle:bind({ 'cmd', 'ctrl' }, 'A', { 'Messages' })
apptoggle:bind({ 'cmd', 'ctrl' }, 'B', { 'TablePlus' }, { 'Lens' }) apptoggle:bind({ 'cmd', 'ctrl' }, 'B', { 'TablePlus' }, { 'Lens' })
apptoggle:bind({ 'cmd', 'ctrl' }, 'C', { 'Calendar' }) apptoggle:bind({ 'cmd', 'ctrl' }, 'C', { 'Calendar' }, { 'Google Calendar' })
apptoggle:bind({ 'cmd', 'ctrl' }, 'D', { 'Mailplane' }, { 'Mimestream' }) apptoggle:bind({ 'cmd', 'ctrl' }, 'D', { 'Mailplane' }, { 'Mimestream' })
apptoggle:bind({ 'cmd', 'ctrl' }, 'E', { 'Emacs', '/Applications/Emacs.app' }) apptoggle:bind({ 'cmd', 'ctrl' }, 'E', { 'Emacs', '/Applications/Emacs.app' })
apptoggle:bind({ 'cmd', 'ctrl' }, 'F', { 'Element' }, { 'Element Nightly' }) apptoggle:bind({ 'cmd', 'ctrl' }, 'F', { 'Element' }, { 'Element Nightly' })
@@ -44,14 +44,15 @@ local function init_url_handler()
uh.url_patterns = { uh.url_patterns = {
{ {
{ {
"%://github.com/krystal/", ".-://github.com/krystal/",
"%://%.github.com/krystal/" ".-://.-.github.com/krystal/",
".-://.-.gitbase..-.k.io/"
}, },
uh.browsers.edge, nil, { "Slack", "Code", "Emacs" } uh.browsers.edge, nil, { "Slack", "Code", "Emacs" }
}, },
{ {
{ "%://meet.google.com/" }, { "%://meet.google.com/" },
chromeProfiles.work, nil, { "Slack", "Calendar" } chromeProfiles.work, nil, { "Slack", "Calendar", "Google Calendar" }
} }
} }
-- uh.url_redir_decoders = { -- uh.url_redir_decoders = {