Last active
June 3, 2020 01:55
-
-
Save feifanzhou/4f5030d370ec9843678253016bfbf899 to your computer and use it in GitHub Desktop.
Karabiner config
This file contains hidden or 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
| { | |
| "global": { | |
| "check_for_updates_on_startup": false, | |
| "show_in_menu_bar": false, | |
| "show_profile_name_in_menu_bar": false | |
| }, | |
| "profiles": [ | |
| { | |
| "complex_modifications": { | |
| "parameters": { | |
| "basic.simultaneous_threshold_milliseconds": 50, | |
| "basic.to_delayed_action_delay_milliseconds": 500, | |
| "basic.to_if_alone_timeout_milliseconds": 1500, | |
| "basic.to_if_held_down_threshold_milliseconds": 500, | |
| "mouse_motion_to_scroll.speed": 100 | |
| }, | |
| "rules": [ | |
| { | |
| "manipulators": [ | |
| { | |
| "description": "Change caps_lock to control or escape.", | |
| "from": { | |
| "key_code": "caps_lock", | |
| "modifiers": { | |
| "optional": [ | |
| "any" | |
| ] | |
| } | |
| }, | |
| "to": [ | |
| { | |
| "key_code": "left_control" | |
| } | |
| ], | |
| "to_if_alone": [ | |
| { | |
| "key_code": "escape" | |
| } | |
| ], | |
| "type": "basic" | |
| } | |
| ] | |
| }, | |
| { | |
| "manipulators": [ | |
| { | |
| "description": "Change mouse button 4 to Cmd+[ (Back)", | |
| "from": { | |
| "pointing_button": "button4" | |
| }, | |
| "to": [ | |
| { | |
| "key_code": "hyphen", | |
| "modifiers": [ | |
| "command" | |
| ] | |
| } | |
| ], | |
| "type": "basic" | |
| } | |
| ] | |
| }, | |
| { | |
| "manipulators": [ | |
| { | |
| "description": "Change Shift + mouse button 4 to Cmd+] (Forward)", | |
| "from": { | |
| "modifiers": { | |
| "mandatory": [ | |
| "left_shift" | |
| ] | |
| }, | |
| "pointing_button": "button4" | |
| }, | |
| "to": [ | |
| { | |
| "key_code": "equal_sign", | |
| "modifiers": [ | |
| "command" | |
| ] | |
| } | |
| ], | |
| "type": "basic" | |
| } | |
| ] | |
| }, | |
| { | |
| "manipulators": [ | |
| { | |
| "description": "Change Option + mouse button 4 to Cmd+W (Close)", | |
| "from": { | |
| "modifiers": { | |
| "mandatory": [ | |
| "left_alt" | |
| ] | |
| }, | |
| "pointing_button": "button4" | |
| }, | |
| "to": [ | |
| { | |
| "key_code": "comma", | |
| "modifiers": [ | |
| "command" | |
| ] | |
| } | |
| ], | |
| "type": "basic" | |
| } | |
| ] | |
| }, | |
| { | |
| "manipulators": [ | |
| { | |
| "description": "Change mouse button 5 to Cmd+Tab (App switcher)", | |
| "from": { | |
| "pointing_button": "button5" | |
| }, | |
| "to": [ | |
| { | |
| "key_code": "tab", | |
| "modifiers": [ | |
| "left_command" | |
| ], | |
| "repeat": false | |
| } | |
| ], | |
| "type": "basic" | |
| } | |
| ] | |
| }, | |
| { | |
| "manipulators": [ | |
| { | |
| "description": "Change Shift + mouse button 5 to Mission Control", | |
| "from": { | |
| "modifiers": { | |
| "mandatory": [ | |
| "left_shift" | |
| ] | |
| }, | |
| "pointing_button": "button5" | |
| }, | |
| "to": [ | |
| { | |
| "key_code": "mission_control", | |
| "repeat": false | |
| } | |
| ], | |
| "type": "basic" | |
| } | |
| ] | |
| }, | |
| { | |
| "manipulators": [ | |
| { | |
| "description": "Change Cmd + mouse button 3 to Cmd+L, Cmd+C", | |
| "from": { | |
| "modifiers": { | |
| "mandatory": [ | |
| "left_command" | |
| ] | |
| }, | |
| "pointing_button": "button3" | |
| }, | |
| "to": [ | |
| { | |
| "key_code": "p", | |
| "modifiers": [ | |
| "command" | |
| ] | |
| }, | |
| { | |
| "key_code": "i", | |
| "modifiers": [ | |
| "command" | |
| ] | |
| } | |
| ], | |
| "type": "basic" | |
| } | |
| ] | |
| }, | |
| { | |
| "manipulators": [ | |
| { | |
| "description": "Change spinny F6 key to media FFD", | |
| "from": { | |
| "key_code": "f21", | |
| "modifiers": { | |
| "mandatory": [ | |
| "left_gui", | |
| "left_alt" | |
| ] | |
| } | |
| }, | |
| "to": [ | |
| { | |
| "key_code": "vk_consumer_next" | |
| } | |
| ], | |
| "type": "basic" | |
| } | |
| ] | |
| }, | |
| { | |
| "manipulators": [ | |
| { | |
| "description": "Change search F5 key to media RWD", | |
| "from": { | |
| "key_code": "f21", | |
| "modifiers": { | |
| "mandatory": [ | |
| "left_alt", | |
| "left_shift" | |
| ] | |
| } | |
| }, | |
| "to": [ | |
| { | |
| "key_code": "vk_consumer_previous" | |
| } | |
| ], | |
| "type": "basic" | |
| } | |
| ] | |
| } | |
| ] | |
| }, | |
| "devices": [ | |
| { | |
| "disable_built_in_keyboard_if_exists": false, | |
| "fn_function_keys": [], | |
| "identifiers": { | |
| "is_keyboard": true, | |
| "is_pointing_device": false, | |
| "product_id": 34304, | |
| "vendor_id": 1452 | |
| }, | |
| "ignore": false, | |
| "manipulate_caps_lock_led": true, | |
| "simple_modifications": [] | |
| }, | |
| { | |
| "disable_built_in_keyboard_if_exists": false, | |
| "fn_function_keys": [], | |
| "identifiers": { | |
| "is_keyboard": true, | |
| "is_pointing_device": false, | |
| "product_id": 2071, | |
| "vendor_id": 1118 | |
| }, | |
| "ignore": false, | |
| "manipulate_caps_lock_led": false, | |
| "simple_modifications": [ | |
| { | |
| "from": { | |
| "key_code": "left_command" | |
| }, | |
| "to": { | |
| "key_code": "left_option" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "left_option" | |
| }, | |
| "to": { | |
| "key_code": "left_command" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "right_command" | |
| }, | |
| "to": { | |
| "key_code": "right_option" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "right_option" | |
| }, | |
| "to": { | |
| "key_code": "right_command" | |
| } | |
| } | |
| ] | |
| }, | |
| { | |
| "disable_built_in_keyboard_if_exists": false, | |
| "fn_function_keys": [], | |
| "identifiers": { | |
| "is_keyboard": true, | |
| "is_pointing_device": false, | |
| "product_id": 636, | |
| "vendor_id": 1452 | |
| }, | |
| "ignore": false, | |
| "manipulate_caps_lock_led": true, | |
| "simple_modifications": [] | |
| }, | |
| { | |
| "disable_built_in_keyboard_if_exists": false, | |
| "fn_function_keys": [], | |
| "identifiers": { | |
| "is_keyboard": false, | |
| "is_pointing_device": true, | |
| "product_id": 17667, | |
| "vendor_id": 2652 | |
| }, | |
| "ignore": false, | |
| "manipulate_caps_lock_led": false, | |
| "simple_modifications": [] | |
| }, | |
| { | |
| "disable_built_in_keyboard_if_exists": false, | |
| "fn_function_keys": [], | |
| "identifiers": { | |
| "is_keyboard": true, | |
| "is_pointing_device": true, | |
| "product_id": 8224, | |
| "vendor_id": 9456 | |
| }, | |
| "ignore": false, | |
| "manipulate_caps_lock_led": false, | |
| "simple_modifications": [] | |
| }, | |
| { | |
| "disable_built_in_keyboard_if_exists": false, | |
| "fn_function_keys": [], | |
| "identifiers": { | |
| "is_keyboard": true, | |
| "is_pointing_device": false, | |
| "product_id": 8224, | |
| "vendor_id": 9456 | |
| }, | |
| "ignore": false, | |
| "manipulate_caps_lock_led": false, | |
| "simple_modifications": [ | |
| { | |
| "from": { | |
| "key_code": "left_command" | |
| }, | |
| "to": { | |
| "key_code": "left_option" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "left_option" | |
| }, | |
| "to": { | |
| "key_code": "left_command" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "right_option" | |
| }, | |
| "to": { | |
| "key_code": "right_command" | |
| } | |
| } | |
| ] | |
| }, | |
| { | |
| "disable_built_in_keyboard_if_exists": false, | |
| "fn_function_keys": [], | |
| "identifiers": { | |
| "is_keyboard": true, | |
| "is_pointing_device": false, | |
| "product_id": 1957, | |
| "vendor_id": 1118 | |
| }, | |
| "ignore": false, | |
| "manipulate_caps_lock_led": false, | |
| "simple_modifications": [ | |
| { | |
| "from": { | |
| "key_code": "left_command" | |
| }, | |
| "to": { | |
| "key_code": "left_option" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "left_option" | |
| }, | |
| "to": { | |
| "key_code": "left_command" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "right_option" | |
| }, | |
| "to": { | |
| "key_code": "right_command" | |
| } | |
| } | |
| ] | |
| } | |
| ], | |
| "fn_function_keys": [ | |
| { | |
| "from": { | |
| "key_code": "f1" | |
| }, | |
| "to": { | |
| "consumer_key_code": "display_brightness_decrement" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "f2" | |
| }, | |
| "to": { | |
| "consumer_key_code": "display_brightness_increment" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "f3" | |
| }, | |
| "to": { | |
| "key_code": "mission_control" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "f4" | |
| }, | |
| "to": { | |
| "key_code": "launchpad" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "f5" | |
| }, | |
| "to": { | |
| "key_code": "illumination_decrement" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "f6" | |
| }, | |
| "to": { | |
| "key_code": "illumination_increment" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "f7" | |
| }, | |
| "to": { | |
| "consumer_key_code": "rewind" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "f8" | |
| }, | |
| "to": { | |
| "consumer_key_code": "play_or_pause" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "f9" | |
| }, | |
| "to": { | |
| "consumer_key_code": "fastforward" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "f10" | |
| }, | |
| "to": { | |
| "consumer_key_code": "mute" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "f11" | |
| }, | |
| "to": { | |
| "consumer_key_code": "volume_decrement" | |
| } | |
| }, | |
| { | |
| "from": { | |
| "key_code": "f12" | |
| }, | |
| "to": { | |
| "consumer_key_code": "volume_increment" | |
| } | |
| } | |
| ], | |
| "name": "Default profile", | |
| "parameters": { | |
| "delay_milliseconds_before_open_device": 1000 | |
| }, | |
| "selected": true, | |
| "simple_modifications": [], | |
| "virtual_hid_keyboard": { | |
| "country_code": 0, | |
| "mouse_key_xy_scale": 100 | |
| } | |
| } | |
| ] | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment