Last active
December 5, 2018 11:16
-
-
Save kbrx93/75e6bde099bafae0ddce6c89bea003ff to your computer and use it in GitHub Desktop.
#tags: 备份
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"title":"caps_lock Enhanced & shift to f19 when pressed alone & tab to hyper by kbrx93", | |
"rules":[ | |
{ | |
"description":"caps_lock + hjklnm,. to arrow and delete", | |
"manipulators":[ | |
{ | |
"type":"basic", | |
"from":{ | |
"key_code":"caps_lock", | |
"modifiers":{ | |
"optional":[ | |
"control", | |
"command", | |
"option", | |
"shift", | |
"fn" | |
] | |
} | |
}, | |
"to":[ | |
{ | |
"set_variable":{ | |
"name":"vi_mode", | |
"value":1 | |
} | |
} | |
], | |
"to_if_alone":[ | |
{ | |
"key_code":"caps_lock" | |
} | |
], | |
"to_after_key_up":[ | |
{ | |
"set_variable":{ | |
"name":"vi_mode", | |
"value":0 | |
} | |
} | |
] | |
}, | |
{ | |
"type":"basic", | |
"from":{ | |
"key_code":"h", | |
"modifiers":{ | |
"optional":[ | |
"control", | |
"command", | |
"option", | |
"shift", | |
"fn" | |
] | |
} | |
}, | |
"to":[ | |
{ | |
"key_code":"left_arrow" | |
} | |
], | |
"conditions":[ | |
{ | |
"type":"variable_if", | |
"name":"vi_mode", | |
"value":1 | |
} | |
] | |
}, | |
{ | |
"type":"basic", | |
"from":{ | |
"key_code":"j", | |
"modifiers":{ | |
"optional":[ | |
"control", | |
"command", | |
"option", | |
"shift", | |
"fn" | |
] | |
} | |
}, | |
"to":[ | |
{ | |
"key_code":"down_arrow" | |
} | |
], | |
"conditions":[ | |
{ | |
"type":"variable_if", | |
"name":"vi_mode", | |
"value":1 | |
} | |
] | |
}, | |
{ | |
"type":"basic", | |
"from":{ | |
"key_code":"k", | |
"modifiers":{ | |
"optional":[ | |
"control", | |
"command", | |
"option", | |
"shift", | |
"fn" | |
] | |
} | |
}, | |
"to":[ | |
{ | |
"key_code":"up_arrow" | |
} | |
], | |
"conditions":[ | |
{ | |
"type":"variable_if", | |
"name":"vi_mode", | |
"value":1 | |
} | |
] | |
}, | |
{ | |
"type":"basic", | |
"from":{ | |
"key_code":"l", | |
"modifiers":{ | |
"optional":[ | |
"control", | |
"command", | |
"option", | |
"shift", | |
"fn" | |
] | |
} | |
}, | |
"to":[ | |
{ | |
"key_code":"right_arrow" | |
} | |
], | |
"conditions":[ | |
{ | |
"type":"variable_if", | |
"name":"vi_mode", | |
"value":1 | |
} | |
] | |
}, | |
{ | |
"type":"basic", | |
"from":{ | |
"key_code":"n", | |
"modifiers":{ | |
"optional":[ | |
"control", | |
"command", | |
"option", | |
"shift", | |
"fn" | |
] | |
} | |
}, | |
"to":[ | |
{ | |
"key_code":"delete_or_backspace" | |
} | |
], | |
"conditions":[ | |
{ | |
"type":"variable_if", | |
"name":"vi_mode", | |
"value":1 | |
} | |
] | |
}, | |
{ | |
"type":"basic", | |
"from":{ | |
"key_code":"m", | |
"modifiers":{ | |
"optional":[ | |
"control", | |
"command", | |
"option", | |
"shift", | |
"fn" | |
] | |
} | |
}, | |
"to":[ | |
{ | |
"key_code":"delete_forward" | |
} | |
], | |
"conditions":[ | |
{ | |
"type":"variable_if", | |
"name":"vi_mode", | |
"value":1 | |
} | |
] | |
}, | |
{ | |
"type":"basic", | |
"from":{ | |
"key_code":"comma", | |
"modifiers":{ | |
"optional":[ | |
"any" | |
] | |
} | |
}, | |
"to":[ | |
{ | |
"key_code":"delete_or_backspace", | |
"modifiers":[ | |
"left_option" | |
] | |
} | |
], | |
"conditions":[ | |
{ | |
"type":"variable_if", | |
"name":"vi_mode", | |
"value":1 | |
} | |
] | |
}, | |
{ | |
"type":"basic", | |
"from":{ | |
"key_code":"period", | |
"modifiers":{ | |
"optional":[ | |
"any" | |
] | |
} | |
}, | |
"to":[ | |
{ | |
"key_code":"delete_forward", | |
"modifiers":[ | |
"left_option" | |
] | |
} | |
], | |
"conditions":[ | |
{ | |
"type":"variable_if", | |
"name":"vi_mode", | |
"value":1 | |
} | |
] | |
}, | |
{ | |
"type":"basic", | |
"from":{ | |
"key_code":"w", | |
"modifiers":{ | |
"optional":[ | |
"any" | |
] | |
} | |
}, | |
"to":[ | |
{ | |
"key_code":"right_arrow", | |
"modifiers":[ | |
"left_option" | |
] | |
} | |
], | |
"conditions":[ | |
{ | |
"type":"variable_if", | |
"name":"vi_mode", | |
"value":1 | |
} | |
] | |
}, | |
{ | |
"type":"basic", | |
"from":{ | |
"key_code":"b", | |
"modifiers":{ | |
"optional":[ | |
"any" | |
] | |
} | |
}, | |
"to":[ | |
{ | |
"key_code":"left_arrow", | |
"modifiers":[ | |
"left_option" | |
] | |
} | |
], | |
"conditions":[ | |
{ | |
"type":"variable_if", | |
"name":"vi_mode", | |
"value":1 | |
} | |
] | |
} | |
] | |
}, | |
{ | |
"description": "left_shift to f19 (in 300milliseconds) when press one", | |
"manipulators": [ | |
{ | |
"type": "basic", | |
"from": { | |
"key_code": "left_shift", | |
"modifiers": { | |
"optional": [ | |
"any" | |
] | |
} | |
}, | |
"to": [ | |
{ | |
"key_code": "left_shift" | |
} | |
], | |
"parameters": { | |
"basic.to_if_alone_timeout_milliseconds": 300 | |
}, | |
"to_if_alone": [ | |
{ | |
"key_code": "fn" | |
}, | |
{ | |
"key_code": "fn" | |
}, | |
{ | |
"key_code": "f19" | |
} | |
] | |
} | |
] | |
}, | |
{ | |
"description": "Change tab key to command+control+option+shift. (Post tab key when pressed alone)", | |
"manipulators": [ | |
{ | |
"type": "basic", | |
"from": { | |
"key_code": "tab", | |
"modifiers": { | |
"optional": [ | |
"control", | |
"option", | |
"shift", | |
"fn" | |
] | |
} | |
}, | |
"to": [ | |
{ | |
"key_code": "left_shift", | |
"modifiers": [ | |
"left_command", | |
"left_control", | |
"left_option" | |
] | |
} | |
], | |
"to_if_alone": [ | |
{ | |
"key_code": "tab" | |
} | |
] | |
} | |
] | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment