.dotfiles/karabiner/karabiner.json
Martin Larsson d9dabcd655 Fix mac keybindings: ctrl(+shift)+backspace now works for word deletion
in both directions. Aerospace doesnt have conflicting keybindings
anymore.
2025-07-14 01:04:11 +02:00

231 lines
10 KiB
JSON

{
"global": { "check_for_updates_on_startup": false },
"profiles": [
{
"complex_modifications": {
"rules": [
{
"description": "Map Cmd+h/j/k/l to Cmd+ArrowKeys and Ctrl+h/j/k/l to original Cmd+h/j/k/l",
"manipulators": [
{
"from": {
"key_code": "h",
"modifiers": {
"mandatory": ["command"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "left_arrow",
"modifiers": ["command"]
}
],
"type": "basic"
},
{
"from": {
"key_code": "h",
"modifiers": {
"mandatory": ["fn"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "h",
"modifiers": ["command"]
}
],
"type": "basic"
},
{
"from": {
"key_code": "j",
"modifiers": {
"mandatory": ["command"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "down_arrow",
"modifiers": ["command"]
}
],
"type": "basic"
},
{
"from": {
"key_code": "j",
"modifiers": {
"mandatory": ["fn"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "j",
"modifiers": ["command"]
}
],
"type": "basic"
},
{
"from": {
"key_code": "k",
"modifiers": {
"mandatory": ["command"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "up_arrow",
"modifiers": ["command"]
}
],
"type": "basic"
},
{
"from": {
"key_code": "k",
"modifiers": {
"mandatory": ["fn"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "k",
"modifiers": ["command"]
}
],
"type": "basic"
},
{
"from": {
"key_code": "l",
"modifiers": {
"mandatory": ["command"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "right_arrow",
"modifiers": ["command"]
}
],
"type": "basic"
},
{
"from": {
"key_code": "l",
"modifiers": {
"mandatory": ["fn"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "l",
"modifiers": ["command"]
}
],
"type": "basic"
}
]
},
{
"description": "Caps Lock → Control when held, Escape when tapped",
"manipulators": [
{
"from": {
"key_code": "caps_lock",
"modifiers": { "optional": ["any"] }
},
"to": [{ "key_code": "left_control" }],
"to_if_alone": [{ "key_code": "escape" }],
"type": "basic"
}
]
},
{
"description": "Escape ↔ Caps Lock toggle",
"manipulators": [
{
"type": "basic",
"from": {
"key_code": "escape",
"modifiers": {
"optional": ["any"]
}
},
"to": [
{
"key_code": "caps_lock"
}
]
},
{
"type": "basic",
"from": {
"key_code": "escape",
"modifiers": {
"mandatory": ["shift"]
}
},
"to": [
{
"key_code": "caps_lock"
}
]
}
]
},
{
"description": "Control+Backspace → Option+Backspace (word deletion)",
"manipulators": [
{
"from": {
"key_code": "delete_or_backspace",
"modifiers": {
"mandatory": ["control"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "delete_or_backspace",
"modifiers": ["option"]
}
],
"type": "basic"
},
{
"from": {
"key_code": "delete_or_backspace",
"modifiers": {
"mandatory": ["control", "shift"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "delete_or_backspace",
"modifiers": ["option", "shift"]
}
],
"type": "basic"
}
]
}
]
},
"name": "Default profile",
"selected": true,
"virtual_hid_keyboard": { "keyboard_type_v2": "iso" }
}
]
}