Hacking on GraphHopper - a Java road routing engine. Peter has posted 62 posts at DZone. You can read more from them at their website. View Full User Profile

Import/Export Code Formatting Settings from NetBeans

  • submit to reddit

In short: To share settings (e.g. code formatting) from NetBeans with Eclipse a little bit of work has to be done. For NetBeans you have the following possibilities

  • Either directly use the file
  • Use the eclipse importer. Now you can use the project within NetBeans and sync etc.

Or  you could load the settings (e.g. the settings from previously imported eclipse project) via “right-clicking the project”->Properties->Formatting->Use project specific options->Load from other projectper-project-settings


Other possibilities? Let me know

From http://karussell.wordpress.com/

Your rating: None
Published at DZone with permission of its author, Peter Karussell.

(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)


Jessica-aileen Alten replied on Tue, 2009/10/06 - 6:34am

Why can't this be done via the checkstyle configuration format? This is a kind of standard, style definitions exists in a lot of companies, there would be one definition source, no more finetuning setting up a project and no problems when sharing a project between Eclipse and Netbeans IDEs.

alex scott replied on Tue, 2009/10/06 - 8:38am

checkstyle would be the best option, although I am struggling to find a checkstyle plugin for netbeans 6.7 that works correctly (checkstyle beans doesnt seem to).

Emmanuel Hugonnet replied on Fri, 2009/10/09 - 3:00pm

I have coded a simple Maven plugin that uses Eclipse's formatter to reformat your Java code:

<a href="http://repository.silverpeas.org/docs/code-formatter/">Maven code formatter plugin</a>

I wanted to do the same with Netbeans own code formatter but I just can't find enought documentation to start.




Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.