Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TEST] Use a more native way to download the git-sdk-64-minimal artifact #2400

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 18 additions & 16 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,17 +16,18 @@ jobs:
displayName: 'Mount test-cache'
env:
GITFILESHAREPWD: $(gitfileshare.pwd)
- task: DownloadBuildArtifacts@0
inputs:
buildType: specific
project: git
pipeline: git-sdk-64-minimal
artifactName: git-sdk-64-minimal
downloadPath: git-sdk-64-minimal
displayName: 'Download git-sdk-64-minimal'
- powershell: |
$urlbase = "https://dev.azure.com/git-for-windows/git/_apis/build/builds"
$id = ((Invoke-WebRequest -UseBasicParsing "${urlbase}?definitions=22&statusFilter=completed&resultFilter=succeeded&`$top=1").content | ConvertFrom-JSON).value[0].id
$downloadUrl = ((Invoke-WebRequest -UseBasicParsing "${urlbase}/$id/artifacts").content | ConvertFrom-JSON).value[1].resource.downloadUrl
(New-Object Net.WebClient).DownloadFile($downloadUrl,"git-sdk-64-minimal.zip")
Expand-Archive git-sdk-64-minimal.zip -DestinationPath . -Force
Remove-Item git-sdk-64-minimal.zip

# Let Git ignore the SDK and the test-cache
"/git-sdk-64-minimal/`n/test-cache/`n" | Out-File -NoNewLine -Encoding ascii -Append "$(Build.SourcesDirectory)\.git\info\exclude"
displayName: 'Download git-sdk-64-minimal'
displayName: 'Tell Git to ignore git-sdk-64-minimal and test-cache'
- powershell: |
& git-sdk-64-minimal\usr\bin\bash.exe -lc @"
ci/make-test-artifacts.sh artifacts
Expand Down Expand Up @@ -144,17 +145,18 @@ jobs:
displayName: 'Mount test-cache'
env:
GITFILESHAREPWD: $(gitfileshare.pwd)
- task: DownloadBuildArtifacts@0
inputs:
buildType: specific
project: git
pipeline: git-sdk-64-minimal
artifactName: git-sdk-64-minimal
downloadPath: git-sdk-64-minimal
displayName: 'Download git-sdk-64-minimal'
- powershell: |
$urlbase = "https://dev.azure.com/git-for-windows/git/_apis/build/builds"
$id = ((Invoke-WebRequest -UseBasicParsing "${urlbase}?definitions=22&statusFilter=completed&resultFilter=succeeded&`$top=1").content | ConvertFrom-JSON).value[0].id
$downloadUrl = ((Invoke-WebRequest -UseBasicParsing "${urlbase}/$id/artifacts").content | ConvertFrom-JSON).value[1].resource.downloadUrl
(New-Object Net.WebClient).DownloadFile($downloadUrl,"git-sdk-64-minimal.zip")
Expand-Archive git-sdk-64-minimal.zip -DestinationPath . -Force
Remove-Item git-sdk-64-minimal.zip

# Let Git ignore the SDK and the test-cache
"/git-sdk-64-minimal/`n/test-cache/`n" | Out-File -NoNewLine -Encoding ascii -Append "$(Build.SourcesDirectory)\.git\info\exclude"
displayName: 'Download git-sdk-64-minimal'
displayName: 'Tell Git to ignore git-sdk-64-minimal and test-cache'
- powershell: |
& git-sdk-64-minimal\usr\bin\bash.exe -lc @"
make NDEBUG=1 DEVELOPER=1 vcxproj
Expand Down