Confirm before exiting Intellij products

If you ever found yourself in a situation where your IntelliJ IDEA (or any other JetBrains product, I guess) was accidentally closed with all the projects at once – this tip is for you.

This happened to me a few times. In my case, I accidentally pressed Exit menu item. So, to prevent closing all your projects use a Confirm before exiting option which is located under: File > Settings > Appearance & Behavior > System Settings.

Intellij confirm exit