6

I'm using Emacs mode for keymap in PyCharm, except in Emacs I'm used to swaps CMD with CTRL. This is setting is enabled in Emacs with (setq mac-command-modifier 'control)

Is there some way to swap CMD/CTRL keys in my Emacs PyCharm keymap that is faster than manually changing it for every shortcut using GUI? IE, is the settings file stored by PyCharm something I can modify directly?

Yaroslav Bulatov
  • 57,332
  • 22
  • 139
  • 197

2 Answers2

0

I'm not sure how you installed PyCharm, but for me on Linux, it's inside ~/pycharm-<version>/lib/resources.jar

Rename the jar to zip and open it. The keymaps folder has the xmls you want to edit.

iamanigeeit
  • 784
  • 1
  • 6
  • 11
  • Thanks, I found the file, but it seems more complicated than I thought, shortcuts are split over several files, and I can't find some of them in any, like "Duplicate Line" – Yaroslav Bulatov Sep 24 '18 at 23:10
0

Honestly it may be easiest to use something like Better Touch Tool to rebind your CMD and CTRL for just PyCharm. This would allow everything else on your machine to function as it ought and still allow for the binding you prefer in PyCharm.

hgoscenski
  • 316
  • 2
  • 5