site:deploy vs. site:stage vs. site:stage-deploy

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

site:deploy vs. site:stage vs. site:stage-deploy

Brad Harper

I've been struggling with multi-module site deployment [via scp] in
conjunction with the dashboard reporting plugin and am convinced that it
must be due to a basic misunderstanding about expected behavior on my
part.

From http://maven.apache.org/plugins/maven-site-plugin/plugin-info.html,
I see

site:site Generates the site for a single project. Note
that links
                  between module sites in a multi module build will not
work.

site:deploy Deploys the generated site using scp or file
                  protocol to the site specified in the
                  <distributionManagement> section of the POM.

site:stage Generates a site in a local staging or mock
directory
                  based on the site url specified in the
                  <distributionManagement> section of the POM.

                  It can be used to test that links between module sites
                  in a multi module build works.

site:stage-       Deploys the generated site to a staging or mock
directory
deploy on the site specified in the <distributionManagement>
                  section of the POM. It also supports scp and file
                  protocols for deployment.

From
http://maven.apache.org/plugins/maven-site-plugin/faq.html#Why_dont_the_
links_between_parent_and_child_modules_work_when_I_run_mvn_site

        What "mvn site" will do for you, in a multi-project build, is to
      run "mvn site" for the parent and all its modules individually.
      The links between parent and child will not work here. They will
      however work when you deploy the site.

      If you want to test this, prior to deployment, you can run the
      site:stage goal as described in the usage documentation instead.

To enable the roll-up behavior for a  multi-module project,
dashboard:dashboard
must be run explicitly *after* the site reports have been generated and
before
deployment, so I run

   mvn site:site dashboard:dashboard site:deploy

but the links between the parent project and its modules don't work,
despite
what the FAQ answer says. A co-worker has run

   mvn site:site; mvn dashboard:dashboard; mvn site:deploy

and the links are intact. Note the separate invocations of maven in
sequence.

I'm not interested in staging, unless that's required. The mojo
description doesn't
make it sound so: "It can be used to test that links ... works [sic]".

Any thoughts? Thanks.

Brad

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]