Skip to content
chris-cale edited this page Feb 24, 2012 · 8 revisions

How to configure eclipse to standardize our indentation:

Project style:

  • Spaces only
  • Indent two spaces

How to change your current indentation style in eclipse:

  1. Navigate to: Eclipse/Preferences

  2. Navigate in the preferences pane to: Java/Code Style/ Formatter

  3. Click on “Edit” and then click “Indentation” on the window that pops up. Now in the “Profile name:” field enter a new profile name such as ‘Openbook Profile’. Then select “spaces only” under the "tab policy" menu and change the value in the “Indentation size:” and “Tab size:” field to 2.

  4. Now click ‘Apply’ and then ‘Ok’

  5. Now you should see your preferences window. Make sure that the “Active profile:” selected is your newly created profile. Then click “Apply” then “Ok” at the bottom of the preferences window to ensure your profile change is set.

Clone this wiki locally