Fix artifact source globbing for extract (#42484)
authorMatt Mitchell <mmitche@microsoft.com>
Mon, 21 Sep 2020 08:27:40 +0000 (01:27 -0700)
committerGitHub <noreply@github.com>
Mon, 21 Sep 2020 08:27:40 +0000 (01:27 -0700)
* Fix artifact source globbing for extract
There was a change the extract AzDO task that fixed a bug where it appeared to be matching some subpaths without globbing.

If you specified foo/x* it would apparently match subpaths of foo. Runtime was relying on this behavior, as the artifact target directory would implicitly get a subdirectory which was the artifact name, but not including that artifact name in the globbing pattern.

Fix this by including ** before the archive.

* Update download-artifact-step.yml

eng/pipelines/installer/jobs/base-job.yml

index 9ad5650..457b92a 100644 (file)
@@ -409,14 +409,14 @@ jobs:
         displayName: 'Unzip $(runtimeFlavorName) artifacts: ${{ platform }}'
         inputs:
           archiveFilePatterns: |
-            $(Build.SourcesDirectory)/__download__/AllPlatforms/$(runtimeFlavorName)Product_${{ platform }}_${{ parameters.liveRuntimeBuildConfig }}.*
+            $(Build.SourcesDirectory)/__download__/AllPlatforms/**/$(runtimeFlavorName)Product_${{ platform }}_${{ parameters.liveRuntimeBuildConfig }}.*
           destinationFolder: $(AllArtifactsDownloadPath)/$(runtimeFlavorName)Product_${{ platform }}_${{ parameters.liveRuntimeBuildConfig }}/
           cleanUnpackFolder: false
       - task: ExtractFiles@1
         displayName: 'Unzip Libraries artifacts: ${{ platform }}'
         inputs:
           archiveFilePatterns: |
-            $(Build.SourcesDirectory)/__download__/AllPlatforms/libraries_bin_${{ platform }}_${{ parameters.liveLibrariesBuildConfig }}.*
+            $(Build.SourcesDirectory)/__download__/AllPlatforms/**/libraries_bin_${{ platform }}_${{ parameters.liveLibrariesBuildConfig }}.*
           destinationFolder: $(AllArtifactsDownloadPath)/libraries_bin_${{ platform }}_${{ parameters.liveLibrariesBuildConfig }}/
           cleanUnpackFolder: false