Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there a keyboard shortcut to revert individual changes in Intellij IDEA?

When a file has changes compared to the version checked-out from the version control system (subversion and cvs in my case), I use Ctrl + Alt + Shift + / Ctrl + Alt + Shift + to jump between those changes. Sometimes I want to revert some of these changes (but not all the changes in the file). I can do that by using the mouse and clicking the little revert-icon with the green arrow, but is there a way to do it from the keyboard (without using the mouse)?

I am using IntelliJ IDEA 7.0.3.

like image 651
Henrik Warne Avatar asked Jan 22 '23 20:01

Henrik Warne


2 Answers

You can set in Setting | Keymap and select Version Control Systems in the keymap list and set the shortcut,but revert action in my subversion settings was set default to Ctrl+Alt+Z

like image 64
Alireza Alallah Avatar answered Jan 25 '23 10:01

Alireza Alallah


You need to assign a hotkey to the Rollback action in Settings | Keymap, it's not assigned by default.

UPDATE: it appears that the Rollback action actually calls Revert for the whole file. I've submitted IDEA-26912 for this, please Watch/Vote.

like image 27
CrazyCoder Avatar answered Jan 25 '23 09:01

CrazyCoder