setWorkspaceName

The setWorkspaceName task changes the name of the specified workspace.

The following table describes setWorkspaceName attributes.

Attribute Description Required

repositoryAddress

Address of the team repository to use. The value of this attribute is typically ${repositoryAddress} because that property is built-in when the Jazz® Build Engine is used.

Yes

userId

User ID for authentication to the repository. Requires password or passwordFile to be set.

Yes

certificateFile

The path to the file that contains the user's login certificate for authentication. Requires password or passwordFile to be set. You can specify certificateFile or repositoriesFile, but not both.

No

password

Password for the user ID for authentication to the repository. Either password or passwordFile can be provided, but not both.

No

passwordFile

The password file to use for authentication to the connection. You can create a suitable password file by invoking the Jazz Build Engine with the -createPasswordFile argument. Only one password file can be specified. Either password or passwordFile can be provided, but not both.

No

smartCard

Use of the connected smart card for authentication (true or false). Requires userId to be set. For more information about smart card authentication, see Connecting to repositories and project areas.

No

failOnError

If true (default value), the task fails if it encounters an error. If false, some errors are ignored and the task is completed.

No

verbose

More message output. The default value is false.

No

name

The name for the workspace. If name is not specified, the name of the workspace identified by the workspaceUUID attribute will be used.

Yes

property

The name of the Ant property in which to return the workspace name.

No

workspaceUUID

The UUID of the workspace for the build. The value of this attribute is typically ${team.scm.workspaceUUID} because the property is build-in when using the Jazz Build Engine.

Yes

Note: Any workspace UUID might be specified, not just the UUID of the build workspace.

Example

Set the name of a workspace


<target name="main">

	<im:setworkspacename
		repositoryAddress="${repositoryAddress}"
		userId="${userId}"
		passwordFile="${passwordFile}"
		name="IMS14.Service.Buildspace.PI12345"
		property="my.property"
		workspaceUUID="${team.scm.workspaceUUID}"
	/>
	<echo>${my.property}</echo>

</target>