Depending on the operating system, go to the IntelliJ IDEA's configuration directory:-Windows: ~\.
Eclipse formatting template IntelliJ formatting template (installation) Reformatting guidelines In general it should be regarded as bad form to reformat code which is not strictly part of a code change. However I am not sure that covers things like the code formatter (identation and the like). To format your code, hit Ctrl + Alt + L This will format your code to the currently set coding standard. We used a free trial version of IntelliJ IDEA Version 3. After this, select Window > Preferences, and open up the configuration for Java > Code Style > Code Formatter. Intellij code style formatter Then in the tree go to: Editor->Code Style->Java, open Import tab (follow numbers on a picture) and apply settings highlighted: Inspections.