Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Using Sublime Text 2 key bindings in PyCharm

Tags:

I would like to use the Sublime Text 2 key bindings in Pycharm. I know how to edit it one by one. Is there a way to override the entire keymap in one shot?

Something like

  • export the key bindings from sublime text 2
  • convert it into Pycharm's format
  • import it into Pycharm

Pycharm has some pre-configured keymaps. If there's a text / XML / JSON file where these maps are stored, I can try to convert it myself.

enter image description here

like image 992
user Avatar asked Sep 25 '13 08:09

user


People also ask

How do I change key bindings in Sublime Text?

Users can customize their key bindings by creating a file named Default. sublime-keymap in their Packages/User/ directory. For example, the following will create a key binding to show unsaved changes, if any exist, via Ctrl+Shift+`.

What is sublime text keymap?

Key bindings in Sublime Text helps a user to process and map the sequences of key presses to actions. They are defined in the JSON format and are stored in . sublime-keymap files. For better integration, it is important to keep separate key map files for Linux, OSX and Windows.


2 Answers

PyCharm now has Sublime Text keymap inbuilt as an alternative to Default Keymap.

Go to Setting -> Keymap and select Sublime Text from Keymap dropdown.

enter image description here

Hope that helps.

like image 123
myusuf Avatar answered Sep 24 '22 01:09

myusuf


After poking around, I feel there's no easy way to do this.

If you change the default bindings, PyCharm creates a file in user space that shows the format of keymap. Theoretically, one could override all the fields in this file. But the problem is, there's no standard way of describing the action performed by a shortcut. Someone will have to do it manually, for each macro, to establish a correspondence between the actions performed by PyCharm & Sublime Text.

like image 22
user Avatar answered Sep 22 '22 01:09

user