9 lines
387 B
Bash
Executable file
9 lines
387 B
Bash
Executable file
#!/bin/sh
|
|
# save-keyboard-shortcuts.sh
|
|
|
|
DESTFILE=~/bin/restore-keyboard-shortcuts.sh
|
|
echo '#!/bin/bash' > $DESTFILE
|
|
|
|
defaults find NSUserKeyEquivalents | sed -e "s/Found [0-9]* keys in domain '\\([^']*\\)':/defaults write \\1 NSUserKeyEquivalents '/" -e "s/ NSUserKeyEquivalents = {//" -e "s/};//" -e "s/}/}'/" >> $DESTFILE
|
|
echo killall cfprefsd >> $DESTFILE
|
|
chmod a+x $DESTFILE
|