Hi there,

I read through this discussion as a Maven user and (sometimes) plugin
developer and also like the idea of more readable POMs. But I also
agree with Jörg's opinion:

>  +1 for more readable POMs
>
>  I personally like the idea of the attributes because it makes
>  it a lot easier to write the POMs, cause you do not have to
>  open and <tag> close a tag </tag> and may end in
>  <groupId>foo</artifactId> copy and paste mistakes.
>
>  However when I scanned the big example
<http://svn.apache.org/viewvc/maven/archiva/trunk/pom-4.1.0.xml?content-type=text%2Fplain&view=co>
>
> I did not get the impression, that it is really easier to read, since your 
> eyes
>  get overdosed by the dominating pattern
>
> <dependency groupId="org.apache.maven.archiva" artifactId=
>
> so you miss the important things even though it is more compact.

The problem with the pattern <dependency
groupId="org.apache.maven.archiva" artifactId= are the missing line
breaks and spaces. Your can't find the information of interest in such
a string. So people will start adding line breaks and you get nearly
the same POM structure as without attributes. Keep in mind that the
white space is your friend when designing something that should be
readable and easy to understand for a human reader.

I have a little suggestion to get dependencies more structured. Move
the <scope> tag of dependencies to group the dependencies. I use this
pattern to keep long lists of dependencies more structured.

<dependencies>
   <compile>
      <dependency>...</dependency>
      <dependency>...</dependency>
      <dependency>...</dependency>
   </compile>
   <runtime>...</runtime>
   <provided>...</provided>
   <test>...</test>
</dependencies>

Best regards,
   Fabian

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to