Kenney Westerhof wrote:

>Resource inheritance from a normal pom seems useless to me since the
>paths are totally different (other project). 
>
Right, that's what I was getting at too.

>Specifying default
>directories for an entire project tree (for users that don't conform to
>the maven2 directory layout) is nice for pom readability, but bad for
>the maven2 directory layout acceptance (i think the m2 directory layout is
>very flexible and allows for extension, so everybody should adopt it :))
>  
>
Maven is about encouraging patterns, but not necessarily our patterns.
Hopefully people will use the defaults for simplicity, but if a company
standard is in force that should be easy too.

>I'd say: use the parent pom's directory value as a default if none is
>specified (inherit, don't merge), and augment the resources set using
>profiles (merge). That would be.... 1 ?
>(Although 3 is almost the same - profile redefine resources means
>overriding?)
>  
>
You're combining 1 and 4.

1 is where the profile (merged) behaves differently to inheritence (not
merged, but inherited as a whole) where 3 is where they behave the same
way (no merge for either, but inherited as a whole)

>If people want to specify different resource sets using profiles, they
>are probably different directories, or different filters.
>If the default resources location is present, then those resources should
>be included regardless of profiles.
>
>If the profile's resources section specifies a different directory, it's
>added, and if it specifies the same directory ('key'), but different
>include/exclude patterns, it's likely the user intented to exclude
>some resources or include some new ones. We can't force them to split up
>according to directories, but this is safest. If we 'augment' the
>includes/excludes, we would need a second set of include/exclude
>parameters to the DirectoryScanner (override-*): if normally the resource
>was excluded, but the override specifies otherwise, include it, and the
>opposite. Technically hard, but intuitive.
>  
>
That sounds reasonable. That given, I'd really prefer we merge
everything (including inheritence and the super POM). I think it is
useful for us to be able to say profiles behave identically to
inheritence (not just from a technical perspective). It's easy to
explain, allows all the features, shouldn't have negative side effects
if you end up with extras (as they just get ignored when they don't
exist), and allows setting a company standard. I definitely agree we can
merge the in/excludes list for a directory as you and John suggested (I
realise now this is different to just aggregating the different
resources sets because of the precedence of excludes).

So... that leads me to 2 now.

Cheers,
Brett

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

Reply via email to