This is the example given on the Artifacts page to collect multiple artifacts at once.
# Collect all .xml files contained in the current working directory recursing sub-directories Get-ChildItem . -Recurse -Include *.xml | New-OctopusArtifact
I have a script step that includes the following line:
Get-ChildItem -Path artifacts -Recurse -Include *.zip | New-OctopusArtifact
It does find every zip in the artifacts directory, but the Task page shows them all as having the same name as the first one uploaded.
For example, if the artifacts directory contains CompTracker50_DEMO.zip and CompTracker50_Dev.zip, they both get uploaded, but they are both name CompTracker50_DEMO.zip:
When I download them, they have the expected contents of both zips, i.e. one has the contents of the Dev .zip, but was named DEMO.
Am I doing something wrong here? I’m terrible at Powershell, and I can’t find any documentation on how New-OctopusArtifact works.