You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Guimiot Isabelle (JIRA)" <ji...@codehaus.org> on 2007/04/16 15:58:46 UTC

[jira] Created: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

site:deploy -> wrong links in ${modules} when artifactId=module's directory
---------------------------------------------------------------------------

                 Key: MSITE-227
                 URL: http://jira.codehaus.org/browse/MSITE-227
             Project: Maven 2.x Site Plugin
          Issue Type: Bug
    Affects Versions: 2.0-beta-5
         Environment: Eclipse IDE
            Reporter: Guimiot Isabelle


I have a problem in the ${modules} part when I run the site:deploy goal.

my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :

workspace/myRoot/
workspace/myModule1/
workspace/myModule2/

my root pom contains this module declaration :

<modules>
	<module>../myModule1</module>
	<module>../myModule1</module>
</modules>

the site:deploy goal gives this structure :
[deploydir]/myRoot/index.html --> root's index
[deploydir]/myRoot/myModule1/index.html --> first module's index
[deploydir]/myRoot/myModule2/index.html --> second module's index

when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :

- in the root page, my links to submodules are like this :

<h5>Modules</h5>
<ul>     
    <li class="none">
       <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
    </li>              
    <li class="none">
       <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
    </li>
</ul>

- and in both modules pages, my link to the parent project is like this :

<h5>Parent project</h5>
<ul>
    <li class="none">
       <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
    </li>
</ul>

The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...

Thanks for your help !



-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Issue Comment Edited: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=250578#action_250578 ] 

Lukas Theussl edited comment on MSITE-227 at 1/5/11 12:37 PM:
--------------------------------------------------------------

I totally agree with everything you say, that's why I opened MSITE-535.

      was (Author: lukas):
    I totally agree with with everything you say, that's why I opened MSITE-535.
  
> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>            Assignee: Lukas Theussl
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Duncan Doyle (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=150975#action_150975 ] 

Duncan Doyle commented on MSITE-227:
------------------------------------

This one is getting weirder by the hour. I fiddled with the <module> definitions a bit to see what will happen to the site distribution URL. When I define the modules in my root POM like this:

<modules>
   <module>../../MyProject/Module1</module>
   <module>../../MyProject/Module2</module>
</modules>

And the site url defined in the root POM is again "file://C:/mavensites/MyProject", the deployed site looks like this:
C:\mavensites\MyProject
C:\MyProject\Module1  
C:\MyProject\Module2

It looks like the definition in the <module> is actually influencing the generated URL....... ?????

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Stefan Hansel (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=253388#action_253388 ] 

Stefan Hansel commented on MSITE-227:
-------------------------------------

Hi Lukas, 
I'm still struggling with this one and I'm happy to accept any workaround possible.

My main goal is just get a report, where childs and masters are linked with relative links (based on the demo project attached here).
The distribution URL is configured in the settings.xml of our buildserver, I have no influence on it. But I can use any url that helps in the project's pom.
As our buildserver then takes the generated sites and puts them somewhere on the webserver relative to the current build number it's important, that the final reports only have relative URLs.

I tried different things now in the url-tags of parent and child, but nothing gives my any succes:

A) your proposed solution:
parent:       <url>file:///tmp/MSITE-227/</url> 
child:        <url>file:///tmp/module1/</url> 
distribution: <url>file:///buildXYZ</url>

=> give absolute links from parent to child and from child to parent => not working for me

B) relative pathes 1
parent:       <url>.</url>
child:        <url>./module1</url>
distribution: <url>file:///buildXYZ</url>

=> creates only relative links between parent + childs.
Unfortunately expects a folder structure, where module1 is withing the parent folder.
But all reports are generated in the same folder (flat structure), so the links are not working.
If I could manipulate the site-deploy target to create a nested folder structure, this would work.

C) relative pathes 2
parent:       <url>.</url>
child:        <url>./../module1</url>
distribution: <url>file:///buildXYZ</url>

parent to child link is relative and working 
child to parent link is relative but not working ("../../../index.html" instead of "../MSITE-227/index.html")


If the created folder structure wasn't flat (i.e. every project in the same folder opposed to having the childs below the parent) then solution (B) what be what I wanted.
This folder structure is already created when artifactID!=foldername but I cannot use this because either I had to rename my VCS-Project names to something strange or I had to rename the artifactID to something strange.

I cannot believe that I'm the first one how wants to create multimodule sites with only relative links to be copied by the buildserver to some other (maven independent) location.



> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>            Assignee: Lukas Theussl
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Stefan Hansel (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=253558#action_253558 ] 

Stefan Hansel commented on MSITE-227:
-------------------------------------

The test project is attached already (the original one and your proposed 'fix' - that only works with absolute URLs),
The bug description by the way is also still correct because trouble with relative links only start when 'artifactID==module directoy'.

Do you really want me to open a new bug-report with the same description and attachments, instead of just reopening this one?

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>            Assignee: Lukas Theussl
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Stefan Hansel (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=249903#action_249903 ] 

Stefan Hansel commented on MSITE-227:
-------------------------------------

I have to kindly disagree.

1) I cannot use absolute URLs in the modules, as this would bind my build to a specific environment. I couldn't run it on my workstation and on the buildserver with the same POM.

2) I cannot use relative URLs. What about projects with multiple layers
A
  -> B
      --> C
      --> D
  ->  E

I want to be able to run a multimodule site for project A and B. If I have to use relative pathes this would work :(

In a multimodule build I want to be able to run a full report, but single developers should also be able to run a report just for a single project.

3) The multimodule site should work out of the box. This bug is the biggest problem a had (and still have) with maven since I started with maven3 a month ago. 
It took me three days to find out what the reason was.

4) Why is it working (out of the box), when the artifactID is different to the directory-anme?
Quoting from the original report: 
{quote}
The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical.
{quote}
I can confirm that just using different artifactIDs workarounds this problem.



I don't see any reason, why the site plugin shouldn't be able to create correct links in a multimodule setups without any workaround?

Please reopen this bug report.

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>            Assignee: Lukas Theussl
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Dennis Lundberg (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dennis Lundberg updated MSITE-227:
----------------------------------

    Fix Version/s:     (was: 2.1.1)

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>         Attachments: MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Issue Comment Edited: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Duncan Doyle (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=150935#action_150935 ] 

mccloud edited comment on MSITE-227 at 10/15/08 6:01 PM:
--------------------------------------------------------------

I think I've got a similar problem. I also use Eclipse with a flat project layout. I have defined a site distribution url in my root pom. My directory layout is like this:

MyProject/MavenRoot
MyProject/Module1
MyProject/Module2

The POM in the MavenRoot includes the modules:
<modules>
    <module>../Module1</module>
    <module>../Module2</module>
</modules>

When the artifactId's of the Modules are NOT equal to the directory-name, and I define the site url as "file://C:/mavensites/MyProject" the deployed site looks like this:

C:\mavensites\MyProject
C:\mavensites\MyProject\ {artifactId Module1}
C:\mavensites\MyProject\ {artifactId Module2}

and the links to the modules work from the main site.

However, when the artifactIds and the directories have exactly the same name, the deployed site looks like this:
C:\mavensites\MyProject
C:\mavensites\ {artifactId Module1}
C:\mavensites\ {artifactId Module2}

and the links to the modules do not work anymore.

I added some debug statements to the maven-site-plugin (version 2.0-beta-7) and saw that the url from "site.getUrl()" in the site-deploy Mojo retrieves a different URL based on the fact whether the directory names and artifactIds match or not.

I did some more testing and found out that this behaviour was not present in Maven 2.0.7, it was introduced in Maven 2.0.8 and is still present in 2.0.9.

      was (Author: mccloud):
    I think I've got a similar problem. I also use Eclipse with a flat project layout. I have defined a site distribution url in my root pom. My directory layout is like this:

MyProject/MavenRoot
MyProject/Module1
MyProject/Module2

The POM in the MavenRoot includes the modules:
<modules>
    <module>../Module1</module>
    <module>../Module2</module>
</modules>

When the artifactId's of the Modules are NOT equal to the directory-name, and I define the site url as "file://C:/mavensites/MyProject" the deployed site looks like this:

C:\mavensites\MyProject
C:\mavensites\MyProject\\{artifactId Module1}
C:\mavensites\MyProject\\{artifactId Module2}

and the links to the modules work from the main site.

However, when the artifactIds and the directories have exactly the same name, the deployed site looks like this:
C:\mavensites\MyProject
C:\mavensites\\{artifactId Module1}
C:\mavensites\\{artifactId Module2}

and the links to the modules do not work anymore.

I added some debug statements to the maven-site-plugin (version 2.0-beta-7) and saw that the url from "site.getUrl()" in the site-deploy Mojo retrieves a different URL based on the fact whether the directory names and artifactIds match or not.

I did some more testing and found out that this behaviour was not present in Maven 2.0.7, it was introduced in Maven 2.0.8 and is still present in 2.0.9.
  
> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Dennis Lundberg (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dennis Lundberg updated MSITE-227:
----------------------------------

    Component/s: multi module

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=250004#action_250004 ] 

Lukas Theussl commented on MSITE-227:
-------------------------------------

I'm not following your points above. If you cannot use absolute URLs and you cannot use relative URLs, then what would you like to use? The point is that in general single modules can be deployed to different locations than what is given by their relative source location. Their final relative locations are determined by the url elements in the poms, as that's where the single sites are supposed to end up at. This is [documented|http://maven.apache.org/plugins/maven-site-plugin/faq.html#Use_of_url] and that's the way it is currently supposed to work. (As a side note, I agree that it shouldn't be like that, see MSITE-535)

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>            Assignee: Lukas Theussl
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=250582#action_250582 ] 

Lukas Theussl commented on MSITE-227:
-------------------------------------

bq. Would it be a temporary workaround to have the site-plugin just create the same folder structure regardless of whether artifactID matches the folder-name of the project?

That's exactly equivalent to implementing MSITE-535 since the folder structure is determined by distributionManagement.site.url

bq. How much can I expect MISTE-535 to be resolved.

I just scheduled it for the next release, I am currently looking at all these deploy/relative link related issues. But I'm a slow worker, so don't ask me for a release date ;)

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>            Assignee: Lukas Theussl
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=253423#action_253423 ] 

Lukas Theussl commented on MSITE-227:
-------------------------------------

Stefan: this issue is closed, please open a new one (linking back to this) and attach a test project. I'll have a look at it.

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>            Assignee: Lukas Theussl
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Lukas Theussl updated MSITE-227:
--------------------------------

    Attachment: MSITE-227.zip

I can reproduce this with the attached test case (both with site-plugin-2.0 and 2.1-SNAPSHOT). The module1 gets deployed incorrectly.

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>             Fix For: 2.1
>
>         Attachments: MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Stefan Hansel (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=253398#action_253398 ] 

Stefan Hansel commented on MSITE-227:
-------------------------------------

even more strange: 
when I use

mvn site:stage 

all links are nice and relative and it just works (regardless of whether I have url tags or not)!

When using
mvn site-deploy 
trouble begins again :(

Doesn't this make this quote from the docs
{quote}To review/test the generated web site before an official deploy, you can stage the site in a specific directory.{quote}
somehow wrong, when links are different in the end?

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>            Assignee: Lukas Theussl
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Lukas Theussl updated MSITE-227:
--------------------------------

    Attachment: MSITE-227-working.zip

The workaround is to specify a {{<url>}} element for all modules and the parent. See attached working test project. Actually I am not sure if this should be called a workaround or the proper solution, I didn't find any docs on it.

Note that with published site-plugin-2.1 the links are ok as well but the modules sites suffer from MSITE-456, which is fixed in 2.1.1-SNAPSHOT.


> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Issue Comment Edited: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Duncan Doyle (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=150935#action_150935 ] 

mccloud edited comment on MSITE-227 at 10/15/08 6:00 PM:
--------------------------------------------------------------

I think I've got a similar problem. I also use Eclipse with a flat project layout. I have defined a site distribution url in my root pom. My directory layout is like this:

MyProject/MavenRoot
MyProject/Module1
MyProject/Module2

The POM in the MavenRoot includes the modules:
<modules>
    <module>../Module1</module>
    <module>../Module2</module>
</modules>

When the artifactId's of the Modules are NOT equal to the directory-name, and I define the site url as "file://C:/mavensites/MyProject" the deployed site looks like this:

C:\mavensites\MyProject
C:\mavensites\MyProject\\{artifactId Module1}
C:\mavensites\MyProject\\{artifactId Module2}

and the links to the modules work from the main site.

However, when the artifactIds and the directories have exactly the same name, the deployed site looks like this:
C:\mavensites\MyProject
C:\mavensites\\{artifactId Module1}
C:\mavensites\\{artifactId Module2}

and the links to the modules do not work anymore.

I added some debug statements to the maven-site-plugin (version 2.0-beta-7) and saw that the url from "site.getUrl()" in the site-deploy Mojo retrieves a different URL based on the fact whether the directory names and artifactIds match or not.

I did some more testing and found out that this behaviour was not present in Maven 2.0.7, it was introduced in Maven 2.0.8 and is still present in 2.0.9.

      was (Author: mccloud):
    I think I've got a similar problem. I also use Eclipse with a flat project layout. I have defined a site distribution url in my root pom. My directory layout is like this:

MyProject/MavenRoot
MyProject/Module1
MyProject/Module2

The POM in the MavenRoot includes the modules:
<modules>
    <module>../Module1</module>
    <module>../Module2</module>
</modules>

When the artifactId's of the Modules are NOT equal to the directory-name, and I define the site url as "file://C:/mavensites/MyProject" the deployed site looks like this:

C:\mavensites\MyProject
C:\mavensites\MyProject\{artifactId Module1}
C:\mavensites\MyProject\{artifactId Module2}

and the links to the modules work from the main site.

However, when the artifactIds and the directories have exactly the same name, the deployed site looks like this:
C:\mavensites\MyProject
C:\mavensites\{artifactId Module1}
C:\mavensites\{artifactId Module2}

and the links to the modules do not work anymore.

I added some debug statements to the maven-site-plugin (version 2.0-beta-7) and saw that the url from "site.getUrl()" in the site-deploy Mojo retrieves a different URL based on the fact whether the directory names and artifactIds match or not.

I did some more testing and found out that this behaviour was not present in Maven 2.0.7, it was introduced in Maven 2.0.8 and is still present in 2.0.9.
  
> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Issue Comment Edited: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Duncan Doyle (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=150975#action_150975 ] 

mccloud edited comment on MSITE-227 at 10/16/08 6:09 AM:
--------------------------------------------------------------

This one is getting weirder by the hour. I fiddled with the <module> definitions a bit to see what will happen to the site distribution URL. When I define the modules in my root POM like this:

<modules>
   <module>../../MyProject/Module1</module>
   <module>../../MyProject/Module2</module>
</modules>

And the site url defined in the root POM is again "file://C:/mavensites/MyProject", the URL used by Wagon for the modules is "file://MyProject/Module1" and "file://MyProject/Module2"

It looks like the definition in the <module> is actually influencing the generated URL....... ?????

      was (Author: mccloud):
    This one is getting weirder by the hour. I fiddled with the <module> definitions a bit to see what will happen to the site distribution URL. When I define the modules in my root POM like this:

<modules>
   <module>../../MyProject/Module1</module>
   <module>../../MyProject/Module2</module>
</modules>

And the site url defined in the root POM is again "file://C:/mavensites/MyProject", the deployed site looks like this:
C:\mavensites\MyProject
C:\MyProject\Module1  
C:\MyProject\Module2

It looks like the definition in the <module> is actually influencing the generated URL....... ?????
  
> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=250578#action_250578 ] 

Lukas Theussl commented on MSITE-227:
-------------------------------------

I totally agree with with everything you say, that's why I opened MSITE-535.

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>            Assignee: Lukas Theussl
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Lukas Theussl updated MSITE-227:
--------------------------------

    Affects Version/s: 2.0

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>             Fix For: 2.1
>
>         Attachments: MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Dennis Lundberg (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=137738#action_137738 ] 

Dennis Lundberg commented on MSITE-227:
---------------------------------------

How do you specify <distributionManagement> and <url> in the parent and child POMs?

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Stefan Hansel (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=253592#action_253592 ] 

Stefan Hansel commented on MSITE-227:
-------------------------------------

Hi Lukas, 

thanks a lot for your help.
I'm now able to get the relative links working even when artifactID matches the module's directory
With some struggling even in maven3, so no need for a new report.

As a reference for other newbies here are the needed snippets

Maven2: 
{code}
<plugin>
  <groupId>org.apache.maven.plugins</groupId>
  <artifactId>maven-site-plugin</artifactId>
  <version>2.3-SNAPSHOT</version>
</plugin>
{code}

Maven3:
{code}
<plugin>
  <groupId>org.apache.maven.plugins</groupId>
  <artifactId>maven-site-plugin</artifactId>
  <version>3.0-beta-3</version>
  <dependencies>
    <dependency>
      <groupId>org.apache.maven.shared</groupId>
      <artifactId>maven-doxia-tools</artifactId>
      <version>1.4-SNAPSHOT</version>
    </dependency>
  </dependencies>
</plugin>
{code}



> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>            Assignee: Lukas Theussl
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Closed: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Lukas Theussl closed MSITE-227.
-------------------------------

    Resolution: Not A Bug
      Assignee: Lukas Theussl

Let's call it the proper solution :) Relative links are calculated from urls, so you have to specify them in all modules if you want links to work.

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>            Assignee: Lukas Theussl
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Stefan Hansel (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=249905#action_249905 ] 

Stefan Hansel commented on MSITE-227:
-------------------------------------

If you don't reopen this bug report, please update the documentation of the site plugin at least with real life examples (that don't use absolute pathes).
This is a big gotcha for first time users of the site plugin in multimodule projects.

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>            Assignee: Lukas Theussl
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "David Matejcek (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=222716#action_222716 ] 

David Matejcek commented on MSITE-227:
--------------------------------------

This is a blocker issue, I cannot find any acceptable workaround to deploy modules into right places AND to generate right links in the parent site.

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>         Attachments: MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=253573#action_253573 ] 

Lukas Theussl commented on MSITE-227:
-------------------------------------

Please try with current site plugin 2.3-SNAPSHOT and yes, open a new issue with a detailed description of expected vs. actual behavior. Thanks.

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>            Assignee: Lukas Theussl
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Duncan Doyle (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=150935#action_150935 ] 

Duncan Doyle commented on MSITE-227:
------------------------------------

I think I've got a similar problem. I also use Eclipse with a flat project layout. I have defined a site distribution url in my root pom. My directory layout is like this:

MyProject/MavenRoot
MyProject/Module1
MyProject/Module2

The POM in the MavenRoot includes the modules:
<modules>
    <module>../Module1</module>
    <module>../Module2</module>
</modules>

When the artifactId's of the Modules are NOT equal to the directory-name, and I define the site url as "file://C:/mavensites/MyProject" the deployed site looks like this:

C:\mavensites\MyProject
C:\mavensites\MyProject\{artifactId Module1}
C:\mavensites\MyProject\{artifactId Module2}

and the links to the modules work from the main site.

However, when the artifactIds and the directories have exactly the same name, the deployed site looks like this:
C:\mavensites\MyProject
C:\mavensites\{artifactId Module1}
C:\mavensites\{artifactId Module2}

and the links to the modules do not work anymore.

I added some debug statements to the maven-site-plugin (version 2.0-beta-7) and saw that the url from "site.getUrl()" in the site-deploy Mojo retrieves a different URL based on the fact whether the directory names and artifactIds match or not.

I did some more testing and found out that this behaviour was not present in Maven 2.0.7, it was introduced in Maven 2.0.8 and is still present in 2.0.9.

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Stefan Hansel (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=250577#action_250577 ] 

Stefan Hansel commented on MSITE-227:
-------------------------------------

But why do I need a workaround (i.e. specifying an URL) at all?
In my project I am not specifying any URL in the poms so the site plugin decides alone where to put each folder. 

In my multimodule build it creates the following structure in the site-deploy dir, when 'artifact-ID = project dirname':
|- parent
|- child1
|- child2
(with broken links)

If 'artifact-ID != project dirname' the following layout is created:

|- parent
|---|-  child 1
|---|-  child 1
(with working links)

I don't even care about the folder structure - but if the site plugin decides for a certain folder structure, why isn't it generating the correct links for it?

Sorry I'm very new to maven - but everyone told me it is about plugin-and-play. Configure important stuff (and leave out all optional stuff, like 'URL'-tags, because otherwise I don't do it the 'maven way').

So what is wrong when I expect the site plugin to create correct links when I don't specify any optional URL tag in the POM?
The maven docs say "url: The URL, like the name, is not required." - so the site plugin should obey that?

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>            Assignee: Lukas Theussl
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Issue Comment Edited: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "David Matejcek (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=222716#action_222716 ] 

David Matejcek edited comment on MSITE-227 at 5/26/10 6:17 AM:
---------------------------------------------------------------

This is a blocker issue, I cannot find any acceptable workaround to deploy modules into right places AND to generate right links in the parent site. Affects also 2.1.

      was (Author: dmatej):
    This is a blocker issue, I cannot find any acceptable workaround to deploy modules into right places AND to generate right links in the parent site.
  
> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>         Attachments: MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Issue Comment Edited: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Stefan Hansel (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=250579#action_250579 ] 

Stefan Hansel edited comment on MSITE-227 at 1/5/11 12:42 PM:
--------------------------------------------------------------

Would it be a temporary workaround to have the site-plugin just create the same folder structure regardless of whether artifactID matches the folder-name of the project?
It's so depressing it already works like I'd expect it in a certain configuration.

How much can I expect MISTE-535 to be resolved. Sounds like a change that breaks backwards compatiblity - are you really going to do that?

      was (Author: stefan.hansel@tolina.de):
    Would it be a temporary workaround to have the site-plugin just create the same folder structure regardless of whether artifactID matches the folder-name of the project?
  
> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>            Assignee: Lukas Theussl
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-227) site:deploy -> wrong links in ${modules} when artifactId=module's directory

Posted by "Stefan Hansel (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=250579#action_250579 ] 

Stefan Hansel commented on MSITE-227:
-------------------------------------

Would it be a temporary workaround to have the site-plugin just create the same folder structure regardless of whether artifactID matches the folder-name of the project?

> site:deploy -> wrong links in ${modules} when artifactId=module's directory
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-227
>                 URL: http://jira.codehaus.org/browse/MSITE-227
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>          Components: multi module
>    Affects Versions: 2.0-beta-5, 2.0
>         Environment: Eclipse IDE
>            Reporter: Guimiot Isabelle
>            Assignee: Lukas Theussl
>         Attachments: MSITE-227-working.zip, MSITE-227.zip
>
>
> I have a problem in the ${modules} part when I run the site:deploy goal.
> my project contains a root module and 2 sub-modules, at the same directory depth (I'm using Eclipse) :
> workspace/myRoot/
> workspace/myModule1/
> workspace/myModule2/
> my root pom contains this module declaration :
> <modules>
> 	<module>../myModule1</module>
> 	<module>../myModule1</module>
> </modules>
> the site:deploy goal gives this structure :
> [deploydir]/myRoot/index.html --> root's index
> [deploydir]/myRoot/myModule1/index.html --> first module's index
> [deploydir]/myRoot/myModule2/index.html --> second module's index
> when the project name (directory name in the workspace) and the artifactId are exactly the same, I have wrong links, both in root and in sub-modules pages :
> - in the root page, my links to submodules are like this :
> <h5>Modules</h5>
> <ul>     
>     <li class="none">
>        <a href="../myModule1/index.html">myModule1</a> <!-- should be "myModule1/index.html" instead -->
>     </li>              
>     <li class="none">
>        <a href="../myModule2/index.html">myModule2</a> <!-- should be "myModule2/index.html" instead -->
>     </li>
> </ul>
> - and in both modules pages, my link to the parent project is like this :
> <h5>Parent project</h5>
> <ul>
>     <li class="none">
>        <a href="../myRoot/index.html">myRoot</a> <!-- should be "../index.html" instead -->
>     </li>
> </ul>
> The weirdest thing is that everything is fine when the artefactId and the eclipse project name (directory) are different !!! the problem appears only when they are identical...
> Thanks for your help !

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira