You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Vincent Massol <vm...@pivolis.com> on 2004/04/30 08:54:03 UTC

[Q] Why maven.xdoc.version properties commented out?

Hi Jason,

Could you please explain why you've commented out all plugin's
project.properties maven.xdoc.version properties? For ex:

## maven.xdoc.version=${pom.currentVersion}

Thanks
-Vincent



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


RE: [Q] Why maven.xdoc.version properties commented out?

Posted by Jason van Zyl <jv...@maven.org>.
On Fri, 2004-04-30 at 08:41, Vincent Massol wrote:

> I like the habit of defining all properties that are configurable in
> plugin.properties. It makes a lot of sense to me and make them visible
> to users. Hiding them in plugin.jelly is not a good practice I'd say.

This is a by product of the architecture-less plugin, and I agree with
you as it is the only place you can really look for a definitive list of
parameters. But it would be easy enough to have a comment like:

## maven.xdoc.version = ${pom.currentVersion}

To indicate the default value. The properites handling for plugins is
convoluted but that's the way it is. As I said I don't particular care
one way or the other for the maven1 plugins, not much you can do about
them now. They work so that's good enough.

> So, I'd say it's really required to do interpolation in
> project.properties. 

Those are two entirely separate things: providing a list of parameters
vs interpolating POM values into properties files. You don't need to
interpolate the POM in order to provide a list of parameters. They are
mutually exclusive.

> Unless we remove project.properties altogether and
> move everything in the POM.

Which is the way things are moving with the maven2 version of the POM.

> Thanks
> -Vincent
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org

-- 
jvz.

Jason van Zyl
jason@maven.org
http://maven.apache.org

happiness is like a butterfly: the more you chase it, the more it will
elude you, but if you turn your attention to other things, it will come
and sit softly on your shoulder ...

 -- Thoreau 


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


RE: [Q] Why maven.xdoc.version properties commented out?

Posted by Vincent Massol <vm...@pivolis.com>.

> -----Original Message-----
> From: Jason van Zyl [mailto:jvanzyl@maven.org]
> Sent: 30 April 2004 14:29
> To: Maven Developers List
> Subject: Re: [Q] Why maven.xdoc.version properties commented out?
> 
> On Fri, 2004-04-30 at 02:54, Vincent Massol wrote:
> > Hi Jason,
> >
> > Could you please explain why you've commented out all plugin's
> > project.properties maven.xdoc.version properties? For ex:
> >
> > ## maven.xdoc.version=${pom.currentVersion}
> 
> The POM is already available within the context of the xdoc plugin so
> you always have access to ${pom.currentVersion}. Also, as I've noted
> before the practice of interpolating the POM the properties which are
> then just used in a plugin where the context already provides access
to
> the POM is bad. That being said, if if makes your life easier put it
> back. The plugins in maven1 are basically architecture-less and there
> are all sorts of silly things so whatever makes things easier is
better
> I suppose.

I would just like to understand what you have replaced it with. You have
removed the definition of the maven.xdoc.version properties in
plugin.properites files but I don't see what you have replaced it with.

The previous behavior was:
- if maven.xdoc.version is not defined, do not print version information
in the generated website
- if it is defined, use the value for the generated website

I've just run a "maven site" on a plugin and I can see the version is
there, even though the maven.xdoc.version property is not defined in
project.properties. Thus, it must be somewhere... ;-)

> 
> But I can't think of a reason why POM interpolation is necessary in
> properties for plugins because you can do whatever you want with the
POM
> already and it just adds to the complexity of plugin processing. The
> only purpose it serves is that the properties file serves as a sort of
> psueudo documentation to show what parameters are available.

I like the habit of defining all properties that are configurable in
plugin.properties. It makes a lot of sense to me and make them visible
to users. Hiding them in plugin.jelly is not a good practice I'd say.

So, I'd say it's really required to do interpolation in
project.properties. Unless we remove project.properties altogether and
move everything in the POM.

Thanks
-Vincent



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: [Q] Why maven.xdoc.version properties commented out?

Posted by Jason van Zyl <jv...@maven.org>.
On Fri, 2004-04-30 at 02:54, Vincent Massol wrote:
> Hi Jason,
> 
> Could you please explain why you've commented out all plugin's
> project.properties maven.xdoc.version properties? For ex:
> 
> ## maven.xdoc.version=${pom.currentVersion}

The POM is already available within the context of the xdoc plugin so
you always have access to ${pom.currentVersion}. Also, as I've noted
before the practice of interpolating the POM the properties which are
then just used in a plugin where the context already provides access to
the POM is bad. That being said, if if makes your life easier put it
back. The plugins in maven1 are basically architecture-less and there
are all sorts of silly things so whatever makes things easier is better
I suppose.

But I can't think of a reason why POM interpolation is necessary in
properties for plugins because you can do whatever you want with the POM
already and it just adds to the complexity of plugin processing. The
only purpose it serves is that the properties file serves as a sort of
psueudo documentation to show what parameters are available.

> Thanks
> -Vincent
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org

-- 
jvz.

Jason van Zyl
jason@maven.org
http://maven.apache.org

happiness is like a butterfly: the more you chase it, the more it will
elude you, but if you turn your attention to other things, it will come
and sit softly on your shoulder ...

 -- Thoreau 


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org