Grégory Joseph wrote: > Hi there, > > I've seen this "topic" debated many times, and still haven't figured > everything out. I was recently confused by the handling and > inheritance of urls in Maven. I think I got most of it, when it comes > to project.url. > > Now, when it comes to deploying a site, I'm baffled. Up to > maven-site-plugin 2.1.1, things seem to be fairly understandable. It > wasn't exactly possible (at least to my understanding) to have > multi-module projects sites deployed in a "versioned" directory > (because ${artifactId}/${version} would be re-interpolated for every > submodule). But at least, I could do a help:effective-pom, and get the > URLs that would be used for deployment. > > Now I just tried 3.1, and I'm baffled that I can't seem to be able to > completely override the distributionManagement.site.url defined by my > parent pom. Using help:effective-pom gives me the URLs I expect, and > the ones i would like Maven to use when deploying the site. However, > the plugin seems to think differently, and tries to upload to > "relativised" urls, somehow inheriting the site url defined in a > corporate parent pom, adding some levels of "../" and finally the path > i'm expecting. > > It kind of sounds like MSITE-600 to me, so I'm unsure if/how the issue > was fixed. Example: > * Corporate parent pom defines this site deployment url: > prot://foo/${artifactId}/${version} -- it works for this pom, and it's > a good enough default for most of our single-module projects. Not the > lack of trailing slash, btw. > * Some multi-module project defines this site deployment url: > prot://foo/xuq/lolcats/${version}. And the resulting deployment urls > end up looking like: > prot://foo/corp-parent/12//../../xuq/lolcats/${version} (and I still > don't know where the double slash comes from)
Normalizing this is exactly the same as prot://foo/xuq/lolcats/${version}, so the deployment location should be correct. Did you try site:stage to check? -Lukas > > So unlike one of the latest comments in MSITE-600, I'm not even trying > to change the protocol. But it seems that either the wagon (i'm using > dav, if that's relevant), or the Nexus instance I have at the > receiving end, don't cope well with those "../". > > Question is two fold: > * Why is the plugin even trying to do that ? Why is it not following > the same rules as effective-pom ? How can one "preview" what urls will > be used, then ? > * How do people really deploy sites with a version number in the path, > when using a "corporate" parent pom, without redefining the site.url > for every single project ? > > Thanks for any hint or tip ! > > Cheers, > -greg > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org