Skip to content

Commit 7363730

Browse files
dschoGit for Windows Build Agent
authored and
Git for Windows Build Agent
committed
Merge pull request #3150 from dscho/ci-cache-vcpkg-artifacts-g4w
ci: cache vcpkg artifacts
2 parents 5143e62 + 6488400 commit 7363730

File tree

1 file changed

+4
-8
lines changed

1 file changed

+4
-8
lines changed

.github/workflows/main.yml

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -184,14 +184,10 @@ jobs:
184184
repository: 'microsoft/vcpkg'
185185
path: 'compat/vcbuild/vcpkg'
186186
- name: download vcpkg artifacts
187-
shell: powershell
188-
run: |
189-
$urlbase = "https://dev.azure.com/git/git/_apis/build/builds"
190-
$id = ((Invoke-WebRequest -UseBasicParsing "${urlbase}?definitions=9&statusFilter=completed&resultFilter=succeeded&`$top=1").content | ConvertFrom-JSON).value[0].id
191-
$downloadUrl = ((Invoke-WebRequest -UseBasicParsing "${urlbase}/$id/artifacts").content | ConvertFrom-JSON).value[0].resource.downloadUrl
192-
(New-Object Net.WebClient).DownloadFile($downloadUrl, "compat.zip")
193-
Expand-Archive compat.zip -DestinationPath . -Force
194-
Remove-Item compat.zip
187+
uses: git-for-windows/get-azure-pipelines-artifact@v0
188+
with:
189+
repository: git/git
190+
definitionId: 9
195191
- name: add msbuild to PATH
196192
uses: microsoft/setup-msbuild@v1
197193
- name: copy dlls to root

0 commit comments

Comments
 (0)