set-artifact-names
- Last updated on December 29, 2023
- •
- Less than a minute to read
This task assigns the names to single artifacts and artifact groups. All artifacts for which we want to set a name must be listed in inputArtifacts
.
Parameters
Each parameter represents a key-value pair, where the key is the artifact (e.g., "result"
), and the value is the assigned name. Values support argument interpolation according to common rules.
If a collection of artifacts is specified as the key (e.g., "result*"
), the name specified in the value (e.g., "hi-res"
) will be assigned to each element in this collection with adding the element index in the collection (result1 - hi-res (1)
, result2 - hi-res (2)
, etc.).
Name override is also supported for a collection element.
Example
{
"description": "Set print file name",
"name": "set-print-file-name",
"type": "set-artifact-name",
"inputArtifacts": [
"preview",
"result*"
],
"parameters": {
"preview": "{{project.items.0.fields.previewFileName?}}",
"result*": "collection name",
"result1": "collection name override"
}
}