我有一个Java多模块Maven项目,我想构建一个MVN站点和javadocs并让CruiseControl将最新的每日构建发布到配置的静态位置。如何将CruiseControl最新构建工件发布到静态URL
麻烦的是CruiseControl artifactPublisher允许您指定一个dest目录,但它是用最后一次构建的最新时间标记的。我希望能够发布到大干快上每个构建覆盖的位置,如:
http://cc-buildserver/cruisecontrol/artifacts/gameplatform-documentation/
artifactPublisher documentation:
DIR - 将所有文件从此 目录复制
dest - 实际的目标目录的父目录 ;实际的 目标目录名称将为 构建时间戳。
子目录 - 独特 (时间戳)目录下 子目录包含 文物
例如,如果我有一个CruiseControl的项目叫gameplatform-documentation
和配置我artifactPublisher这样:
<project name="gameplatform-documentation" forceOnly="true" requireModification="false" forceBuildNewProject="false" buildafterfailed="false">
...
<schedule>
<composite time="2300">
<maven2
mvnhome="${mvn.home}"
pomfile="${dev.root}/gameplatform-parent/pom.xml"
goal="site" />
</composite>
</schedule>
<publishers>
<artifactspublisher
dir="${dev.root}/gameplatform-parent/target/site"
dest="artifacts/gameplatform-documentation" />
</publishers>
</project>
我结束了我的Maven生成的网站和javadocs在不同的目录中生成:
http://cc-buildserver/cruisecontrol/cruisecontrol/artifacts/gameplatform-documentation/20091110130202/
也许我需要使用自定义AntPublisher或FTPPublisher,并创建另一个Web服务器来托管发布的文档。我也可以使用CC源代码控制工具,并将文档签入我们的SVN服务器并使用它来提供文档。
这是如何实现的?