My tribe like to switch their control and caps lock keys. I know how to do this† from the GUI. I'd like to go one step further, and put this step in my nascent dotfiles/osx file. Does anyone know how to do this from the command line, say using the
† If you have more than one keyboard (e.g. you use an external keyboard with your notebook), you must remap each keyboard, while they are attached, using the dropdown on the preferences dialog.