0 Replies Latest reply: Sep 5, 2011 12:37 PM by Karel Piwko RSS

    ShrinkWrap Dependency Resolver updated formatting

    Karel Piwko Master

      Hello ShrinkWrap Resolver developers!


      ShrinkWrap Dependency Resolver is now using JBoss Community formatter for all the code (SHRINKWRAP-324).

      Please update your IDE configurations, maven-checkstyle plugin won't allow differently formatted code to pass.


      You can get ShrinkWrap Dependency Resolver from https://github.com/shrinkwrap/resolver


      IDE Agnostic Instructions

      Formatting Java files:


      • JavaDoc parameter information is on the same line, not indented
      • Line length is 128 characters
      • Spaces are used instead of tabs
      • Switch blocks are indented
      • Indentation size is 4


      Formatting Resource Files

      All of resources files have to follow these conventions:

      • Line length is 128 characters
      • Spaces are used instead of tabs
      • Indentation size is 4



      Formatters for Eclipse and IDEA can be downloaded from: https://github.com/jbossas/jboss-as/tree/master/ide-configs


      In Eclipse (instructions valid for 3.6 and 3.7) , set following:


      • Window -> Preferences -> Java -> Code Style -> Formatter -- set the correct file here, e.g.

      the one from https://github.com/jbossas/jboss-as/blob/master/ide-configs/eclipse/as7formatter.xml


      • Window -> Preferences -> Java -> Editor -> Save Actions -- set Additional Actions and enable "Remove trailing whitespace on all lines"


      Detailed informations are located at: