This page last changed on Mar 14, 2009 by dcameron.

The Build Publisher lets you copy any arbitrary files on a successful build.
You can set alwaysPublish to true, if you want the copy always to happen.

Example


<buildpublisher>
     <sourceDir>C:\myprojects\project1</sourceDir>
     <publishDir>\\myfileserver\project1</publishDir>
     <useLabelSubDirectory>false</useLabelSubDirectory>
     <alwaysPublish>false</alwaysPublish>
</buildpublisher>


This will copy the contents of C:\myprojects\project1 to the network share \\myfileserver\project1.

Minimal Configuration Example

<buildpublisher />


This will copy the contents of the project's working directory to a new label subdirectory under the project's artifact directory (i.e. <artifact_dir>\<label_dir>)

Configuration Elements:

Node Description Type Required Default
sourceDir The source directory to copy files from. This path can be absolute or can be relative to the project's working directory. If unspecified, the project's working directory will be used as the source directory. string false n/a
publishDir The directory to copy the files to. This path can be absolute or can be relative to the project's artifact directory. If useLabelSubDirectory is true (default) a subdirectory with the current build's label will be created, and the contents of sourceDir will be copied to it. If unspecified, the project's artifact directory will be used as the publish directory. string false n/a
useLabelSubDirectory If set to true (the default value), files will be copied to subdirectory under the publishDir which will be named with the label for the current integration. bool false true
alwaysPublish always copies the files, regardless of the state of the build
bool
false
false
description If filled in, this will be shown in the buildstage as the process name
string
false
n/a

This block used to support an 'additionalDir' attribute. This feature has been removed - just use multiple <buildpublisher> blocks to achieve the same job.
The useLabelSubDirectory property has been added in 1.2.

Document generated by Confluence on Mar 14, 2009 02:55