You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Sam Barnett-Cormack <s....@lancaster.ac.uk> on 2009/09/08 14:40:53 UTC

Confusion with site:deploy

Hi all,

I'm a bit confused about the deployment paths used by site:deploy. I 
have the following in my parent POM:

   <distributionManagement>
     <site>
       <id>mnementh</id>
       <url>file://M:\public_html\maven\${project.artifactId}</url>
     </site>
   </distributionManagement>

Now, when the parent POM's site is being generated, it puts it at 
M:\public_html\maven\parent-name, which is intended. However, for the 
inheritors (which we'll call project-1 and project-2), I get them at 
M:\public_html\maven\project-1\project-1 and 
M:\public_html\maven\project-2\project-2. This is far from handy, and 
spoils my attempts to define the URLs in the parent using
   <url>http://shed.geekworld.co.uk/~sdb/maven/${project.artifactId}</url>

I'm confused. Can anyone explain?

-- 
Sam Barnett-Cormack

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


Re: Confusion with site:deploy

Posted by Sam Barnett-Cormack <s....@lancaster.ac.uk>.
Mick Knutson wrote:
> This happens because ${project.artifactId} changes as you build the parent,
> then the children. Then you will always have the child DIR appended to that.
> 
> ${project.artifactId}/project-1 while in project-1 is ${project.artifactId}
> == project-1
> 
> Sounds like you are trying to build a multi-module documentation, but NOT
> want to create a multi-module structure with inheritance.

Well, I don't want all the projects under each other, and certainly not 
under the parent. I have another project, let's call it 'complete', that 
identifies all but the parent as modules, and when I build it it builds 
everything (obviously). The aim of that one is to aggregate everything, 
so I get a site with combined javadoc, etc etc, and a combined src jar 
and javadoc jar. IIRC I call each module a module and a dependency, to 
avoid order-of-build problems.

Layout I want:

maven/complete
maven/parent
maven/project-1
maven/project-2

Layout I'd accept:

maven/complete
maven/parent
maven/complete/project-1
maven/complete/project-2

(all referring to site directories on the generated website, of course)

> On Tue, Sep 8, 2009 at 9:04 AM, Sam Barnett-Cormack <
> s.barnett-cormack@lancaster.ac.uk> wrote:
> 
>> Mick Knutson wrote:
>>
>>> You could define another <distributionManagement> in your children.
>>> Otherwise, just hard-code your parent artifactId then reference:
>>>
>> I'd really like to understand why this is happening. As I see it, one of
>> the points of parent POMs and parameters is the ability to configure this
>> sort of thing in one place.
>>
>>  in Parent:
>>> M:\public_html\maven\project-parent
>>>
>>> Then reference your children from your Parent as:
>>>
>>> ./project-1
>>> ./project-2
>>>
>> I've separated aggregation from inheritance, so the parent doesn't refer to
>> children at all. I build them all from within another project, which also
>> inherits the same parent, but declares all of the others as modules.
>>
>>  On Tue, Sep 8, 2009 at 8:40 AM, Sam Barnett-Cormack <
>>> s.barnett-cormack@lancaster.ac.uk> wrote:
>>>
>>>  Hi all,
>>>> I'm a bit confused about the deployment paths used by site:deploy. I have
>>>> the following in my parent POM:
>>>>
>>>>  <distributionManagement>
>>>>   <site>
>>>>     <id>mnementh</id>
>>>>     <url>file://M:\public_html\maven\${project.artifactId}</url>
>>>>   </site>
>>>>  </distributionManagement>
>>>>
>>>> Now, when the parent POM's site is being generated, it puts it at
>>>> M:\public_html\maven\parent-name, which is intended. However, for the
>>>> inheritors (which we'll call project-1 and project-2), I get them at
>>>> M:\public_html\maven\project-1\project-1 and
>>>> M:\public_html\maven\project-2\project-2. This is far from handy, and
>>>> spoils
>>>> my attempts to define the URLs in the parent using
>>>>  <url>http://shed.geekworld.co.uk/~sdb/maven/${project.artifactId}<http://shed.geekworld.co.uk/%7Esdb/maven/$%7Bproject.artifactId%7D>
>>>> <http://shed.geekworld.co.uk/%7Esdb/maven/$%7Bproject.artifactId%7D>
>>>> </url>
>>>>
>>>> I'm confused. Can anyone explain?
>>>>
>>>> --
>>>> Sam Barnett-Cormack
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>>>> For additional commands, e-mail: users-help@maven.apache.org
>>>>
>>>>
>>>>
>> --
>> Sam Barnett-Cormack
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>> For additional commands, e-mail: users-help@maven.apache.org
>>
>>
> 


-- 
Sam Barnett-Cormack

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


Re: Confusion with site:deploy

Posted by Mick Knutson <mi...@gmail.com>.
This happens because ${project.artifactId} changes as you build the parent,
then the children. Then you will always have the child DIR appended to that.

${project.artifactId}/project-1 while in project-1 is ${project.artifactId}
== project-1

Sounds like you are trying to build a multi-module documentation, but NOT
want to create a multi-module structure with inheritance.


---
Thank You…

Mick Knutson, President

BASE Logic, Inc.
Enterprise Architecture, Design, Mentoring & Agile Consulting
p. (866) BLiNC-411: (254-6241-1)
f. (415) 685-4233

Website: http://baselogic.com
Linked IN: http://linkedin.com/in/mickknutson
Vacation Rental: http://tahoe.baselogic.com
---



On Tue, Sep 8, 2009 at 9:04 AM, Sam Barnett-Cormack <
s.barnett-cormack@lancaster.ac.uk> wrote:

> Mick Knutson wrote:
>
>> You could define another <distributionManagement> in your children.
>> Otherwise, just hard-code your parent artifactId then reference:
>>
>
> I'd really like to understand why this is happening. As I see it, one of
> the points of parent POMs and parameters is the ability to configure this
> sort of thing in one place.
>
>  in Parent:
>> M:\public_html\maven\project-parent
>>
>> Then reference your children from your Parent as:
>>
>> ./project-1
>> ./project-2
>>
>
> I've separated aggregation from inheritance, so the parent doesn't refer to
> children at all. I build them all from within another project, which also
> inherits the same parent, but declares all of the others as modules.
>
>  On Tue, Sep 8, 2009 at 8:40 AM, Sam Barnett-Cormack <
>> s.barnett-cormack@lancaster.ac.uk> wrote:
>>
>>  Hi all,
>>>
>>> I'm a bit confused about the deployment paths used by site:deploy. I have
>>> the following in my parent POM:
>>>
>>>  <distributionManagement>
>>>   <site>
>>>     <id>mnementh</id>
>>>     <url>file://M:\public_html\maven\${project.artifactId}</url>
>>>   </site>
>>>  </distributionManagement>
>>>
>>> Now, when the parent POM's site is being generated, it puts it at
>>> M:\public_html\maven\parent-name, which is intended. However, for the
>>> inheritors (which we'll call project-1 and project-2), I get them at
>>> M:\public_html\maven\project-1\project-1 and
>>> M:\public_html\maven\project-2\project-2. This is far from handy, and
>>> spoils
>>> my attempts to define the URLs in the parent using
>>>  <url>http://shed.geekworld.co.uk/~sdb/maven/${project.artifactId}<http://shed.geekworld.co.uk/%7Esdb/maven/$%7Bproject.artifactId%7D>
>>> <http://shed.geekworld.co.uk/%7Esdb/maven/$%7Bproject.artifactId%7D>
>>> </url>
>>>
>>> I'm confused. Can anyone explain?
>>>
>>> --
>>> Sam Barnett-Cormack
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>>> For additional commands, e-mail: users-help@maven.apache.org
>>>
>>>
>>>
>>
>
> --
> Sam Barnett-Cormack
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

Re: Confusion with site:deploy

Posted by Sam Barnett-Cormack <s....@lancaster.ac.uk>.
Mick Knutson wrote:
> You could define another <distributionManagement> in your children.
> Otherwise, just hard-code your parent artifactId then reference:

I'd really like to understand why this is happening. As I see it, one of 
the points of parent POMs and parameters is the ability to configure 
this sort of thing in one place.

> in Parent:
> M:\public_html\maven\project-parent
> 
> Then reference your children from your Parent as:
> 
> ./project-1
> ./project-2

I've separated aggregation from inheritance, so the parent doesn't refer 
to children at all. I build them all from within another project, which 
also inherits the same parent, but declares all of the others as modules.

> On Tue, Sep 8, 2009 at 8:40 AM, Sam Barnett-Cormack <
> s.barnett-cormack@lancaster.ac.uk> wrote:
> 
>> Hi all,
>>
>> I'm a bit confused about the deployment paths used by site:deploy. I have
>> the following in my parent POM:
>>
>>  <distributionManagement>
>>    <site>
>>      <id>mnementh</id>
>>      <url>file://M:\public_html\maven\${project.artifactId}</url>
>>    </site>
>>  </distributionManagement>
>>
>> Now, when the parent POM's site is being generated, it puts it at
>> M:\public_html\maven\parent-name, which is intended. However, for the
>> inheritors (which we'll call project-1 and project-2), I get them at
>> M:\public_html\maven\project-1\project-1 and
>> M:\public_html\maven\project-2\project-2. This is far from handy, and spoils
>> my attempts to define the URLs in the parent using
>>  <url>http://shed.geekworld.co.uk/~sdb/maven/${project.artifactId}<http://shed.geekworld.co.uk/%7Esdb/maven/$%7Bproject.artifactId%7D>
>> </url>
>>
>> I'm confused. Can anyone explain?
>>
>> --
>> Sam Barnett-Cormack
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>> For additional commands, e-mail: users-help@maven.apache.org
>>
>>
> 


-- 
Sam Barnett-Cormack

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


Re: Confusion with site:deploy

Posted by Mick Knutson <mi...@gmail.com>.
You could define another <distributionManagement> in your children.
Otherwise, just hard-code your parent artifactId then reference:

in Parent:
M:\public_html\maven\project-parent

Then reference your children from your Parent as:

./project-1
./project-2



---
Thank You…

Mick Knutson, President

BASE Logic, Inc.
Enterprise Architecture, Design, Mentoring & Agile Consulting
p. (866) BLiNC-411: (254-6241-1)
f. (415) 685-4233

Website: http://baselogic.com
Linked IN: http://linkedin.com/in/mickknutson
Vacation Rental: http://tahoe.baselogic.com
---



On Tue, Sep 8, 2009 at 8:40 AM, Sam Barnett-Cormack <
s.barnett-cormack@lancaster.ac.uk> wrote:

> Hi all,
>
> I'm a bit confused about the deployment paths used by site:deploy. I have
> the following in my parent POM:
>
>  <distributionManagement>
>    <site>
>      <id>mnementh</id>
>      <url>file://M:\public_html\maven\${project.artifactId}</url>
>    </site>
>  </distributionManagement>
>
> Now, when the parent POM's site is being generated, it puts it at
> M:\public_html\maven\parent-name, which is intended. However, for the
> inheritors (which we'll call project-1 and project-2), I get them at
> M:\public_html\maven\project-1\project-1 and
> M:\public_html\maven\project-2\project-2. This is far from handy, and spoils
> my attempts to define the URLs in the parent using
>  <url>http://shed.geekworld.co.uk/~sdb/maven/${project.artifactId}<http://shed.geekworld.co.uk/%7Esdb/maven/$%7Bproject.artifactId%7D>
> </url>
>
> I'm confused. Can anyone explain?
>
> --
> Sam Barnett-Cormack
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>