❌Karabiner-ElementsでWarpのhotkey設定をする
RaycastでApplicationをtoggleする設定の方が精度が良いのでそっちを使うことにしたmrsekut.icon
Warp
下記設定を追加することでalt-spaceでtoggleできる
code:hokey.json
{
"title": "Toggle Warp with alt-space",
"rules": [
{
"description": "Toggle Warp with alt-space",
"manipulators": [
{
"type": "basic",
"from": {
"key_code": "spacebar",
"modifiers": {
"mandatory": "left_alt",
"optional": "any"
}
},
"to": [
{
"shell_command": "osascript -e 'tell application \"System Events\"' -e 'if visible of process \"Warp\" is true then' -e 'set visible of process \"Warp\" to false' -e 'else' -e 'tell application \"Warp\" to activate' -e 'end if' -e 'end tell'"
}
]
}
]
}
]
}
shell_commandのところでAppleScriptを実行している
参考
Karabiner-Elementsに設定を追加する