With this helper, you can:
- write your
Complex Modification
rule as YAML instead of JSON.- More precisely, the YAML file is converted to a JSON file.
- load/reload your rule automatically in the
Karabiner-Elements Preferences
window.
Demo.mov
-
Install Homebrew.
-
Install
fswatch
andyq
.
$ brew install fswatch yq
- Clone this repository.
$ git clone [email protected]:su10/Karabiner-Elements-Helper.git && cd Karabiner-Elements-Helper
- Write your rule as a YAML file in
~/.config/karabiner/assets/complex_modifications/
.
$ touch ~/.config/karabiner/assets/complex_modifications/my_rules.yml
$ vim ~/.config/karabiner/assets/complex_modifications/my_rules.yml
- Convert the YAML file to a JSON file.
$ ./yaml_to_json.sh ~/.config/karabiner/assets/complex_modifications/
If you want to test your rule immediately, run watch.sh
to watch changes of the file and reload automatically.
$ ./watch.sh