Skip to content

Instantly share code, notes, and snippets.

@joyofdata
Last active January 15, 2025 15:42
Show Gist options
  • Save joyofdata/ad125527769f529959e797541f1be4cd to your computer and use it in GitHub Desktop.
Save joyofdata/ad125527769f529959e797541f1be4cd to your computer and use it in GitHub Desktop.
MacBook key remappings for Cherry keyboard
https://github.com/rux616/karabiner-windows-mode
and as Complex Modification:
{
"description": "Remap AltGr+Q to @ etc",
"manipulators": [
{
"description": "@",
"from": {
"key_code": "q",
"modifiers": {
"mandatory": ["right_option"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "l",
"modifiers": ["right_option"]
}
],
"type": "basic"
},
{
"description": "{",
"from": {
"key_code": "7",
"modifiers": {
"mandatory": ["right_option"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "8",
"modifiers": ["right_option"]
}
],
"type": "basic"
},
{
"description": "}",
"from": {
"key_code": "0",
"modifiers": {
"mandatory": ["right_option"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "9",
"modifiers": ["right_option"]
}
],
"type": "basic"
},
{
"description": "[",
"from": {
"key_code": "8",
"modifiers": {
"mandatory": ["right_option"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "5",
"modifiers": ["right_option"]
}
],
"type": "basic"
},
{
"description": "]",
"from": {
"key_code": "9",
"modifiers": {
"mandatory": ["right_option"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "6",
"modifiers": ["right_option"]
}
],
"type": "basic"
},
{
"description": "|",
"from": {
"key_code": "non_us_backslash",
"modifiers": {
"mandatory": ["right_option"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "7",
"modifiers": ["right_option"]
}
],
"type": "basic"
},
{
"description": "backslash",
"from": {
"key_code": "hyphen",
"modifiers": {
"mandatory": ["right_option"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "7",
"modifiers": ["right_option", "left_shift"]
}
],
"type": "basic"
},
{
"description": "~",
"from": {
"key_code": "close_bracket",
"modifiers": {
"mandatory": ["right_option"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "n",
"modifiers": ["right_option"]
}
],
"type": "basic"
},
{
"description": "Caps Lock as Alt Gr",
"from": {
"key_code": "caps_lock",
"modifiers": {}
},
"to": [
{
"key_code": "right_option",
"modifiers": []
}
],
"type": "basic"
},
{
"from": { "key_code": "print_screen" },
"to": [{ "shell_command": "open -a screenshot.app" }],
"type": "basic"
}
]
}
---
technically this should restrict application to the external keyboard (add to every modification item as attribute):
"conditions": [
{
"identifiers": [
{
"product_id": 277,
"vendor_id": 1130
}
],
"type": "device_if"
}
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment