As a developer I spend most of my time at work in my IDE, for me that IDE is IntelliJ IDEA. During these years I have learned a few tricks, some useful keyboard-shortcuts and found a few plugins that have helped me be more effective in my day-to-day work. I want to share these lessons with you in the form of 4 IntelliJ ninja tricks!
2 min read
By Ketil S. Velle
December 10, 2019
First and foremost, learning some keyboard shortcuts will yield great awards. And the good thing in IntelliJ is that to start off you only need one:
CMD + SHIFT + A (find actions)*. This keyboard shortcut of shortcuts gives you access to all possible actions within IntelliJ, and their corresponding keyboard shortcut!
The second thing I love to use in IntelliJ is Scratch files (
CTRL + SHIFT + N) . I use these as temporary notes or, after choosing a fitting extension, as a quick way to prettify the json or xml structure I want to look at. These files will not be saved as part of your project, and will disappear as you close them. This way you do not have to worry that they end up in your git-repository by mistake.
My third ninja-trick is concerned with debugging. If you have to test a branch of your code, and want a specific method to return a certain value you can set a breakpoint and use an action called Force return. Using the find actions from my first tip, this is easy to find. Great for those nutty corner cases!
Lastly I want to recommend some great plugins that exists in the marketplace:
These are my four ninja tricks to get the most out of IntelliJ - what are yours?
* Keep in mind that the default keyboard shortcuts may vary from Mac, Linux and Windows. Check them out in the Keymap reference in IntelliJ (Also easily available in find actions) or online here: https://www.jetbrains.com/help/idea/mastering-keyboard-shortcuts.html