Skip to content

Instantly share code, notes, and snippets.

@guerbai
Last active June 2, 2019 04:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save guerbai/2d3d98f6409452d5951ac4aa0e735b2f to your computer and use it in GitHub Desktop.
Save guerbai/2d3d98f6409452d5951ac4aa0e735b2f to your computer and use it in GitHub Desktop.
poker karabiner配置
{
"title": "change application",
"rules": [
{
"description": "change application use poker",
"manipulators": [
{
"type": "basic",
"from": {
"key_code": "a",
"modifiers": {
"mandatory": [
"left_option",
"left_command"
]
},
"optional": [
"any"
]
},
"to": [
{
"key_code": "left_arrow",
"modifiers": [
"left_command"
]
}
]
},
{
"type": "basic",
"from": {
"key_code": "d",
"modifiers": {
"mandatory": [
"left_option",
"left_command"
]
},
"optional": [
"any"
]
},
"to": [
{
"key_code": "right_arrow",
"modifiers": [
"left_command"
]
}
]
}
]
}
]
}
{
"title": "poker arrow keys",
"rules": [
{
"description": "holing left alt and asdw use arrow keys.",
"manipulators": [
{
"type": "basic",
"from": {
"key_code": "a",
"modifiers": {
"mandatory": ["left_option"]
},
"optional": ["any"]
},
"to": [
{
"key_code": "left_arrow"
}
]
},
{
"type": "basic",
"from": {
"key_code": "w",
"modifiers": {
"mandatory": ["left_option"]
},
"optional": ["any"]
},
"to": [
{
"key_code": "up_arrow"
}
]
},
{
"type": "basic",
"from": {
"key_code": "s",
"modifiers": {
"mandatory": ["left_option"]
},
"optional": ["any"]
},
"to": [
{
"key_code": "down_arrow"
}
]
},
{
"type": "basic",
"from": {
"key_code": "d",
"modifiers": {
"mandatory": ["left_option"]
},
"optional": ["any"]
},
"to": [
{
"key_code": "right_arrow"
}
]
},
{
"type": "basic",
"from": {
"key_code": "spacebar",
"modifiers": {
"mandatory": ["left_command"]
},
"optional": ["any"]
},
"to": [
{
"key_code": "return_or_enter"
}
]
},
{
"type": "basic",
"from": {
"key_code": "left_option",
"modifiers": {
"optional": [
"any"
]
}
},
"to": [
{
"key_code": "left_option"
}
],
"to_if_alone": [
{
"key_code": "delete_or_backspace"
}
]
}
]
}
]
}
// 放到/Users/cuishunhua/.config/karabiner/assets/complex_modifications/guerbai-keymap.json
{
"title": "poker arrow keys",
"rules": [
{
"description": "holing left alt and asdw use arrow keys.",
"manipulators": [
{
"from": {
"key_code": "a",
"modifiers": {
"mandatory": [
"left_option"
],
"optional": [
"any"
]
}
},
"to": [
{
"key_code": "left_arrow"
}
],
"type": "basic"
},
{
"from": {
"key_code": "s",
"modifiers": {
"mandatory": [
"left_option"
],
"optional": [
"any"
]
}
},
"to": [
{
"key_code": "down_arrow"
}
],
"type": "basic"
},
{
"from": {
"key_code": "w",
"modifiers": {
"mandatory": [
"left_option"
],
"optional": [
"any"
]
}
},
"to": [
{
"key_code": "up_arrow"
}
],
"type": "basic"
},
{
"from": {
"key_code": "d",
"modifiers": {
"mandatory": [
"left_option"
],
"optional": [
"any"
]
}
},
"to": [
{
"key_code": "right_arrow"
}
],
"type": "basic"
},
{
"from": {
"key_code": "spacebar",
"modifiers": {
"mandatory": ["left_command"],
"optional": ["any"]
}
},
"to": [
{
"key_code": "return_or_enter"
}
],
"type": "basic"
},
{
"from": {
"key_code": "left_option",
"modifiers": {
"optional": ["any"]
}
},
"to": [
{
"key_code": "left_option"
}
],
"to_if_alone": [
{
"key_code": "delete_or_backspace"
}
],
"type": "basic"
},
{
"from": {
"key_code": "a",
"modifiers": {
"mandatory": [
"left_option",
"left_command"
]
},
"optional": [
"any"
]
},
"to": [
{
"key_code": "left_arrow",
"modifiers": [
"left_command"
]
}
],
"type": "basic"
},
{
"type": "basic",
"from": {
"key_code": "d",
"modifiers": {
"mandatory": [
"left_option",
"left_command"
]
},
"optional": [
"any"
]
},
"to": [
{
"key_code": "right_arrow",
"modifiers": [
"left_command"
]
}
]
}
]
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment