Forked from lauri/gist:84674ab22aafc4e0f398a52a53cfd7ec
Last active
April 30, 2018 20:05
-
-
Save mukhortov/d0043f5071efa3b6fb22a45102b3e4ba to your computer and use it in GitHub Desktop.
Remap section sign key (§) to ESC (useful if you have a MacBook Pro with touch bar)
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
#!/bin/bash | |
# | |
# Remap section sign key (§) to ESC | |
# | |
# 0x700000064 - section sign (§) key below ESC | |
# 0x700000029 - ESC | |
# | |
# https://developer.apple.com/library/content/technotes/tn2450/_index.html | |
# | |
# Display current user key mapping setup: | |
# $ hidutil property --get "UserKeyMapping" | |
# | |
# Reset user key mapping: | |
# $ hidutil property --set '{"UserKeyMapping": ""}' | |
# | |
hidutil property --set '{"UserKeyMapping": [{ | |
"HIDKeyboardModifierMappingSrc":0x700000064, | |
"HIDKeyboardModifierMappingDst":0x700000029 | |
}]}' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment