Releasing A Maven Plugin

Releasing a Maven plugin is much the same as any other Maven project. The following guide walks through most of the steps:

Note that plugins have particular conventions for deploying the project site. When encountered in the release process above, perform the following steps:

Staging the latest documentation

Once the release is prepared, but before the release vote, the site needs to be staged.

The plugin parent POM will be configured to publish the documentation in Apache svn https://svn.apache.org/repos/infra/websites/production/maventest/content/plugins/maven-XXX-plugin-staging (TODO: configure pubScmUrl)

Stage the documentation for the current release version (not the new snapshot).

cd target/checkout

mvn -Preporting site site:stage scm-publish:publish-scm
# waiting for POM configuration, add -Dscmpublish.pubScmUrl=scm:svn:https://svn.apache.org/repos/infra/websites/production/maventest/content/plugins/maven-XXX-plugin-staging

Note: You should verify the deployment of the site on the Maven website (you need to wait snvpubsub), which should be a matter of seconds.

http://maven.apache.org/plugins/maven-XXX-plugin-staging/

Publishing the release website

After the release has passed, the site needs to be updated:

  1. cut the new release
    svn cp https://svn.apache.org/repos/infra/websites/production/maventest/content/plugins/maven-XXX-plugin-staging \
           https://svn.apache.org/repos/infra/websites/production/maventest/content/plugins/maven-XXX-plugin-Y.Z
  2. declare the plugins/maven-XXX-plugin-Y.Z directory in extpaths.txt, locally or with the CMS.
  3. edit the content/filtered-resources/.htaccess file (locally or with the CMS) to update rewrite rule
    RewriteRule ^plugins/maven-XXX-plugin/(.*)$ /plugins/maven-XXX-plugin-Y.Z/$1 [L]

(alternative) Publishing the release website without maintaining versioned history

Publish the documentation for the current release version.

cd target/checkout

mvn -Preporting site site:stage scm-publish:publish-scm
# waiting for POM configuration, add -Dscmpublish.pubScmUrl=scm:svn:https://svn.apache.org/repos/infra/websites/production/maventest/content/plugins/maven-XXX-plugin

Updating the Maven site

Use the CMS to update the plugins page, made easy with the CMS bookmarklet.

idea to be developped if sufficient people is interested

Instead of doing command line svn and extpaths.txt + .htaccess edits, the staging/release operations could be automated as web ui like following:

  • http://cms.apache.org/maventest/release/plugins/maven-xxx-plugin-X.Y could display a page proposing to stage the release documentation (doing svn command and .htaccess edit)
  • next time this page is displayed, with the content already available in svn, the page could propose 2 different actions: drop the staged documentation (with extpaths.txt removal) or publish the release website.