Modified:
websites/production/maventest/content/plugins/maven-scm-publish-plugin/index.html
==============================================================================
---
websites/production/maventest/content/plugins/maven-scm-publish-plugin/index.html
(original)
+++
websites/production/maventest/content/plugins/maven-scm-publish-plugin/index.html
Tue Sep 4 13:03:59 2012
@@ -13,7 +13,7 @@
</style>
<link rel="stylesheet" href="./css/print.css" type="text/css"
media="print" />
<meta name="author" content="Benson Margulies" />
- <meta name="Date-Creation-yyyymmdd" content="20120225" />
+ <meta name="Date-Creation-yyyymmdd" content="20120904" />
<meta name="Date-Revision-yyyymmdd" content="20120904" />
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
@@ -185,7 +185,7 @@
</div>
<div id="bodyColumn">
<div id="contentBox">
- <!-- Licensed to the Apache Software Foundation (ASF) under one
--><!-- or more contributor license agreements. See the NOTICE file --><!--
distributed with this work for additional information --><!-- regarding
copyright ownership. The ASF licenses this file --><!-- to you under the
Apache License, Version 2.0 (the --><!-- "License"); you may not use this file
except in compliance --><!-- with the License. You may obtain a copy of the
License at --><!-- --><!-- http://www.apache.org/licenses/LICENSE-2.0 --><!--
--><!-- Unless required by applicable law or agreed to in writing, --><!--
software distributed under the License is distributed on an --><!-- "AS IS"
BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY --><!-- KIND, either express or
implied. See the License for the --><!-- specific language governing
permissions and limitations --><!-- under the License. --><!-- NOTE: For help
with the syntax of this file, see: --><!-- http://maven.apache.org/doxia/referen
ces/apt-format.html --><div class="section"><h2>Maven SCM Publish Plugin<a
name="Maven_SCM_Publish_Plugin"></a></h2><p>The maven-scm-publish-plugin is a
utility plugin to allow Apache projects to publish Maven websites via the ASF
svnpubsub system, and more generally to publish a site generated by Maven or
any content to any supported SCM. In addition to SCM operations, it takes care
to fix newline inconsistencies generated by <tt>maven-site-plugin</tt>, which
prevents simple content import to SCM.</p><p>The plugin provides two goals:
<b>prepare</b> and <b>publish</b>. (TODO: deprecated by new <b>publish-scm</b>
goal, which does everything in one step) </p><p>The prepare goal checks out the
contents of a directory from the SCM into (by default)
<tt>target/scmpublish-checkout</tt>. It then lists the files known to the SCM
and stores them in (by default) <tt>target/scmpublish-inventory.js</tt>. This
provides the point of reference for an eventual SCM checkin. Then it deletes e
very files to let a clean place for site generation.</p><p>After running the
prepare goal, the POM must run <tt>site</tt> phase then <tt>site:stage</tt>
goal, with the <i>stagingDirectory</i> set to
<tt>target/scmpublish-checkout</tt>.</p><p>Finally, the <b>publish</b> goal
compares the output of <tt>site:stage</tt> with the inventory from the
<b>prepare</b> goal, and issues appropriate SCM commands to add and delete,
followed by a checkin.</p><p>The <i>scmpublish.dryRun</i> parameter to the
<b>publish</b> goal avoids all SCM operations, and simply logs out the added,
deleted, and changed files.</p><p>The <b>scmpublish.skipCheckin</b> parameter
omits the final checkin. This allows you to visit
<tt>target/scmpublish-checkout</tt>, and validate its contents before
submitting to the SCM.</p></div><div class="section"><h2>Publishing any content
to SCM<a name="Publishing_any_content_to_SCM"></a></h2><p>Even without any
pom.xml/Maven project, you can update SCM content with a loca
l content:</p><div class="source"><pre>mvn scm-publish:publish-scm
-Dscmpublish.pubScmUrl=scm:...
-Dscmpublish.content=...path-to-content...</pre></div><p>SCM content will be
checked-out to a temporary directory, then local content will be applied to the
check-out, before it is checked-in back.</p><p>See <a
href="./examples/importing-maven-site.html">maven.apache.org content import
script</a> for an example.</p></div><div class="section"><h2>Known
Limitations<a name="Known_Limitations"></a></h2><p>There are 2 known
limitations:</p><ul><li><b>the plugin doesn't create the initial SCM
directory</b>, it just updates content from an existing SCM directory. Then you
need to manually create the empty directory first (with <tt>svn mkdir URL</tt>
for example),</li><li>the plugin works well for multi-module websites
publishing to a complete directory: you just need to publish <tt>mvn
site:stage</tt> content. But if one module does not publish its content to the
same directory (like S
urefire or Enforcer, which have a base directory and one plugin in
<tt>/plugins/</tt>), this staging area can't be simply
imported,</li></ul></div><div class="section"><h2>Future Dreams<a
name="Future_Dreams"></a></h2><p>Ideally, scm urls would be supported in
<tt><distributionManagement</tt>> section of the POM, then publishing
would simply be <tt>mvn site-deploy</tt>, without any problems for non-flat
multi-modules sites.</p><p>To reach such a dream, there are some
steps:</p><ul><li>fix inconsistent newlines generated by
<tt>maven-site-plugin</tt> (caused by site.vm template and resources taken from
skin jar without fixing newlines)</li><li>improve <a
href="/wagon/wagon-providers/wagon-scm/"><tt>wagon-scm</tt></a> to put a whole
directory content in one commit, and not with one commit per
file.</li></ul><p>Then this plugin will be outdated, replaced by natural
<tt>maven-site-plugin</tt>.</p></div>
+ <!-- Licensed to the Apache Software Foundation (ASF) under one
--><!-- or more contributor license agreements. See the NOTICE file --><!--
distributed with this work for additional information --><!-- regarding
copyright ownership. The ASF licenses this file --><!-- to you under the
Apache License, Version 2.0 (the --><!-- "License"); you may not use this file
except in compliance --><!-- with the License. You may obtain a copy of the
License at --><!-- --><!-- http://www.apache.org/licenses/LICENSE-2.0 --><!--
--><!-- Unless required by applicable law or agreed to in writing, --><!--
software distributed under the License is distributed on an --><!-- "AS IS"
BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY --><!-- KIND, either express or
implied. See the License for the --><!-- specific language governing
permissions and limitations --><!-- under the License. --><!-- NOTE: For help
with the syntax of this file, see: --><!-- http://maven.apache.org/doxia/referen
ces/apt-format.html --><div class="section"><h2>Maven SCM Publish Plugin<a
name="Maven_SCM_Publish_Plugin"></a></h2><p>The maven-scm-publish-plugin is a
utility plugin to allow Apache projects to publish Maven websites via the ASF
svnpubsub system, and more generally to publish a site generated by Maven or
any content to any supported SCM. In addition to SCM operations, it takes care
to fix newline inconsistencies generated by <tt>maven-site-plugin</tt>, which
prevents simple content import to SCM.</p><p>The plugin has been tested with
git scm too and by example can push content for github pages too.</p><p>The
plugin provides two goals: <b>prepare</b> and <b>publish</b>. (TODO: deprecated
by new <b>publish-scm</b> goal, which does everything in one step) </p><p>The
prepare goal checks out the contents of a directory from the SCM into (by
default) <tt>target/scmpublish-checkout</tt>. It then lists the files known to
the SCM and stores them in (by default) <tt>target/scmpublis
h-inventory.js</tt>. This provides the point of reference for an eventual SCM
checkin. Then it deletes every files to let a clean place for site
generation.</p><p>After running the prepare goal, the POM must run
<tt>site</tt> phase then <tt>site:stage</tt> goal, with the
<i>stagingDirectory</i> set to
<tt>target/scmpublish-checkout</tt>.</p><p>Finally, the <b>publish</b> goal
compares the output of <tt>site:stage</tt> with the inventory from the
<b>prepare</b> goal, and issues appropriate SCM commands to add and delete,
followed by a checkin.</p><p>The <i>scmpublish.dryRun</i> parameter to the
<b>publish</b> goal avoids all SCM operations, and simply logs out the added,
deleted, and changed files.</p><p>The <b>scmpublish.skipCheckin</b> parameter
omits the final checkin. This allows you to visit
<tt>target/scmpublish-checkout</tt>, and validate its contents before
submitting to the SCM.</p></div><div class="section"><h2>Publishing any content
to SCM<a name="Publishing_any_co
ntent_to_SCM"></a></h2><p>Even without any pom.xml/Maven project, you can
update SCM content with a local content:</p><div class="source"><pre>mvn
scm-publish:publish-scm -Dscmpublish.pubScmUrl=scm:...
-Dscmpublish.content=...path-to-content...</pre></div><p>SCM content will be
checked-out to a temporary directory, then local content will be applied to the
check-out, before it is checked-in back.</p><p>See <a
href="./examples/importing-maven-site.html">maven.apache.org content import
script</a> for an example.</p></div><div class="section"><h2>Known
Limitations<a name="Known_Limitations"></a></h2><p>There are 2 known
limitations:</p><ul><li>For svn the plugin can create the initial SCM directory
if not exist. But for git by example if you use a branch the branch won't be
created , you have to create it manually.</li><li>the plugin works well for
multi-module websites publishing to a complete directory: you just need to
publish <tt>mvn site:stage</tt> content. But if one modu
le does not publish its content to the same directory (like Surefire or
Enforcer, which have a base directory and one plugin in <tt>/plugins/</tt>),
this staging area can't be simply imported,</li></ul></div><div
class="section"><h2>Future Dreams<a name="Future_Dreams"></a></h2><p>Ideally,
scm urls would be supported in <tt><distributionManagement</tt>> section
of the POM, then publishing would simply be <tt>mvn site-deploy</tt>, without
any problems for non-flat multi-modules sites.</p><p>To reach such a dream,
there are some steps:</p><ul><li>fix inconsistent newlines generated by
<tt>maven-site-plugin</tt> (caused by site.vm template and resources taken from
skin jar without fixing newlines)</li><li>improve <a
href="/wagon/wagon-providers/wagon-scm/"><tt>wagon-scm</tt></a> to put a whole
directory content in one commit, and not with one commit per
file.</li></ul><p>Then this plugin will be outdated, replaced by natural
<tt>maven-site-plugin</tt>.</p></div>
</div>
</div>
<div class="clear">