mirror of
https://github.com/kogakure/dotfiles.git
synced 2026-02-03 20:25:30 +00:00
feat(karabiner): add modification to mute/unmute MS Teams with the keyboard
This commit is contained in:
1
karabiner/assets/complex_modifications/1669799628.json
Normal file
1
karabiner/assets/complex_modifications/1669799628.json
Normal file
@@ -0,0 +1 @@
|
||||
{"title":"Keychron K8 Microphone Button to Microsoft Teams Mute","rules":[{"description":"Focus Microsoft Teams Meeting Manager Window","manipulators":[{"from":{"modifiers":{"mandatory":["fn"]},"key_code":"spacebar"},"conditions":[{"type":"frontmost_application_unless","bundle_identifiers":["com.microsoft.teams"]}],"to":[{"shell_command":"if [ $(ps aux | grep -v grep | grep -ci \"Microsoft Teams.app/Contents/Frameworks/Microsoft Teams Helper.app\") -gt 0 ]; then osascript -e 'activate application id \"com.microsoft.teams\"' -e 'tell application \"System Events\" to keystroke \"m\" using {command down, shift down}'; fi","lazy":true,"repeat":true}],"type":"basic"}]},{"description":"Change Fn + Spacebar to Shift + Cmd + A","manipulators":[{"type":"basic","from":{"modifiers":{"mandatory":["fn"]},"key_code":"spacebar"},"conditions":[{"type":"frontmost_application_if","bundle_identifiers":["^com\\.microsoft\\.teams$"]}],"to":[{"key_code":"m","modifiers":["left_shift","left_gui"]}]}]}]}
|
||||
@@ -228,6 +228,70 @@
|
||||
"type": "basic"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"description": "Focus Microsoft Teams Meeting Manager Window",
|
||||
"manipulators": [
|
||||
{
|
||||
"conditions": [
|
||||
{
|
||||
"bundle_identifiers": [
|
||||
"com.microsoft.teams"
|
||||
],
|
||||
"type": "frontmost_application_unless"
|
||||
}
|
||||
],
|
||||
"from": {
|
||||
"key_code": "spacebar",
|
||||
"modifiers": {
|
||||
"mandatory": [
|
||||
"fn"
|
||||
]
|
||||
}
|
||||
},
|
||||
"to": [
|
||||
{
|
||||
"lazy": true,
|
||||
"repeat": true,
|
||||
"shell_command": "if [ $(ps aux | grep -v grep | grep -ci \"Microsoft Teams.app/Contents/Frameworks/Microsoft Teams Helper.app\") -gt 0 ]; then osascript -e 'activate application id \"com.microsoft.teams\"' -e 'tell application \"System Events\" to keystroke \"m\" using {command down, shift down}'; fi"
|
||||
}
|
||||
],
|
||||
"type": "basic"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"description": "Change Fn + Spacebar to Shift + Cmd + A",
|
||||
"manipulators": [
|
||||
{
|
||||
"conditions": [
|
||||
{
|
||||
"bundle_identifiers": [
|
||||
"^com\\.microsoft\\.teams$"
|
||||
],
|
||||
"type": "frontmost_application_if"
|
||||
}
|
||||
],
|
||||
"from": {
|
||||
"key_code": "spacebar",
|
||||
"modifiers": {
|
||||
"mandatory": [
|
||||
"fn"
|
||||
]
|
||||
}
|
||||
},
|
||||
"to": [
|
||||
{
|
||||
"key_code": "m",
|
||||
"modifiers": [
|
||||
"left_shift",
|
||||
"left_gui"
|
||||
]
|
||||
}
|
||||
],
|
||||
"type": "basic"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user