You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
673 B

  1. #!/bin/bash
  2. #a tool to fix broken keymaps as a result of pull request #190
  3. #changing the declaration of matrix_scan_user() and matrix_init_user()
  4. #
  5. #This script will save a copy of the specified keymap as keymap.c.bak
  6. #and then create a new keymap.c with the definion corrected.
  7. #this script must be run from the ergodox_ez directory
  8. if [ $# -ne 1 ]; then
  9. echo $0: usage: ./190hotfix keymap_name
  10. exit 1
  11. fi
  12. echo Saving backup as ./keymaps/$1/keymap.c.bak ...
  13. mv ./keymaps/$1/keymap.c ./keymaps/$1/keymap.c.bak
  14. echo Modifying ./keymaps/$1/keymap.c ...
  15. cat ./keymaps/$1/keymap.c.bak | sed -r 's/^void \* matrix_/void matrix_/'>./keymaps/$1/keymap.c
  16. echo Complete!