Not to swap, but to remap that capslock key in your keyboard to ctrl.
If the file doesn't exist, create ~/.Xmodmap in your home directory, then add these...
keycode 66 = Control_L
clear Lock
add Control = Control_L
and then run: (在.bashrc裏添加)
xmodmap ~/.xmodmap