Eclipse IDE Java Editor Save Actions option should be used by all developers as it helps to keep code clean and organized.
Eclipse is the most widely used IDE for Java programming as it provides a lot of features and it has the support of many free and paid plugins. Most important it is free to use and works flawlessly on any platform like Windows, Mac, Linux Desktops.
For most of the works, it’s default settings are enough to do development work for most of the people.
Eclipse provides one option to keep your code clean, organized, pretty, and most important it can modify your code automatically to make correct use while you save your code.
To enable and customize this option you simply need to open Preferences-> Java-> Editor-> Save Actions and check to “Perform the selected action on save”.
After this check Format Source Code, Organize Imports and Additional actions then click on configure.
Now you can configure code organizing, code style, member accesses, missing codes, and Unused code options. This option should be configured based on your own preferences and practices you follow.
I personally don’t like to auto-sort members and removed unused local variables and private function removals. So I don’t enable that in organizing and cleanup.