What is the advantage of the 'src/main/java'' convention?

Posted by Chris on Stack Overflow See other posts from Stack Overflow or by Chris
Published on 2010-06-09T09:52:34Z Indexed on 2010/06/09 10:02 UTC
Read the original article Hit count: 308

Filed under:
|
|
|

I've noticed that a lot of projects have the following structure:

  • Project-A
    • bin
    • lib
    • src
      • main
        • java
          • RootLevelPackageClass.java

I currently use the following convention (as my projects are 100% java):

  • Project-A
    • bin
    • lib
    • src
      • RootLevelPackageClass.java

I'm not currently using Maven but am wondering if this is a Maven convention or not or if there is another reason. Can someone explain why the first version is so popular these days and if I should adopt this new convention or not?

Chris

© Stack Overflow or respective owner

Related posts about java

Related posts about best-practices