Reading Time: 3 minutes
Here are some small features that may not be apparent to the newer devs that leverage the JetBrain IDEs. Most of them I discovered by using the.
- Double Shift for navigating your codebase
- cmd/ctrl + shift + f for text search
- Remote Interpreters
- Syncing settings
For many including myself this is the primary way to navigate code and files. Simply press shift two times, type in the file, class or function you are searching for and press enter. This is by far the quickest and most accurate way to navigate code in any Editor or IDE I’ve tried so far.
Do it once, and you will not go back.
CMD + Shift + F
Windows & Linux: ctrl + shift + f
This is somewhat similar to 2x Shift. The main difference is that double shifts searches mainly for filenames and symbols (function names, class names, etc.) while CMD shift f functions more like a text search.
If you ever loose something in your code or maybe your are new to the project and don’t know where certain parts are located, this is the way to find it.
This is a huge one for me! JetBrains allows you tu run the code on remote machines. This extends also to all the packages you install, the shell in the terminal is automatically opened on the host.
Remote hosts can be either a machine in which you ssh into, a local docker container running a different version of the language that you need.
You might ask why?
- Use a docker container with a specific version of node/python/php/etc. instead of installing it locally on your machine. Basically a virtual environment for every language. Amazing!
- Maybe you want to run the code on a Raspberry Pi, which has a different architecture. So all the packages you install will be installed on the Raspberry and when you hit command+r the code will execute not on your machine but you still get the logs. Incredible!
To configure simply go to the run menu and add a new remote interpreter.
Sync Settings across devices
This is very simple. You can sync all your settings, including plugins, to either your JetBrain account or your own git settings repository. When you open the IDE some where else, everything is back to how it was.
Enable by going to: File -> Sync IDE Settings
Note: The synchronisation is per-IDE-basis, so your WebStorm settings are not synced with your PyCharm settings of course.
Yet again a one of the reasons why I can’t go back to VSCode. For each language there is a TON of customisation possible when reformatting. You can decide how your spaces should look, commas, imports, semicolons, everything is completely up to you.
You can tinker around with it in the Settings under: Editor -> Code Style -> <your language>
Bonus: If you select on a folder in the project view, you can reformat all files inside it, quick and easy. This is especially useful if one has imported some external sources for example.
Thats it, I hope you found some of it useful and that you can enjoy the JetBrain cosmos even more 😉