зеркало из https://github.com/microsoft/git.git
Merge branch 'js/ci-sdk-download-fix'
Instead of downloading Windows SDK for CI jobs for windows builds from an external site (wingit.blob.core.windows.net), use the one created in the windows-build job, to work around quota issues at the external site. * js/ci-sdk-download-fix: ci: avoid pounding on the poor ci-artifacts container
This commit is contained in:
Коммит
55df1a69d7
|
@ -44,7 +44,19 @@ jobs:
|
||||||
- uses: actions/checkout@v1
|
- uses: actions/checkout@v1
|
||||||
- name: download git-sdk-64-minimal
|
- name: download git-sdk-64-minimal
|
||||||
shell: bash
|
shell: bash
|
||||||
run: a=git-sdk-64-minimal && mkdir -p $a && curl -# https://wingit.blob.core.windows.net/ci-artifacts/$a.tar.xz | tar -C $a -xJf -
|
run: |
|
||||||
|
## Get artifact
|
||||||
|
urlbase=https://dev.azure.com/git-for-windows/git/_apis/build/builds
|
||||||
|
id=$(curl "$urlbase?definitions=22&statusFilter=completed&resultFilter=succeeded&\$top=1" |
|
||||||
|
jq -r ".value[] | .id")
|
||||||
|
download_url="$(curl "$urlbase/$id/artifacts" |
|
||||||
|
jq -r '.value[] | select(.name == "git-sdk-64-minimal").resource.downloadUrl')"
|
||||||
|
curl --connect-timeout 10 --retry 5 --retry-delay 0 --retry-max-time 240 \
|
||||||
|
-o artifacts.zip "$download_url"
|
||||||
|
|
||||||
|
## Unzip and remove the artifact
|
||||||
|
unzip artifacts.zip
|
||||||
|
rm artifacts.zip
|
||||||
- name: build
|
- name: build
|
||||||
shell: powershell
|
shell: powershell
|
||||||
env:
|
env:
|
||||||
|
@ -62,6 +74,11 @@ jobs:
|
||||||
with:
|
with:
|
||||||
name: windows-artifacts
|
name: windows-artifacts
|
||||||
path: artifacts
|
path: artifacts
|
||||||
|
- name: upload git-sdk-64-minimal
|
||||||
|
uses: actions/upload-artifact@v1
|
||||||
|
with:
|
||||||
|
name: git-sdk-64-minimal
|
||||||
|
path: git-sdk-64-minimal
|
||||||
windows-test:
|
windows-test:
|
||||||
runs-on: windows-latest
|
runs-on: windows-latest
|
||||||
needs: [windows-build]
|
needs: [windows-build]
|
||||||
|
@ -70,9 +87,6 @@ jobs:
|
||||||
nr: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
|
nr: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v1
|
- uses: actions/checkout@v1
|
||||||
- name: download git-sdk-64-minimal
|
|
||||||
shell: bash
|
|
||||||
run: a=git-sdk-64-minimal && mkdir -p $a && curl -# https://wingit.blob.core.windows.net/ci-artifacts/$a.tar.xz | tar -C $a -xJf -
|
|
||||||
- name: download build artifacts
|
- name: download build artifacts
|
||||||
uses: actions/download-artifact@v1
|
uses: actions/download-artifact@v1
|
||||||
with:
|
with:
|
||||||
|
@ -81,6 +95,11 @@ jobs:
|
||||||
- name: extract build artifacts
|
- name: extract build artifacts
|
||||||
shell: bash
|
shell: bash
|
||||||
run: tar xf artifacts.tar.gz
|
run: tar xf artifacts.tar.gz
|
||||||
|
- name: download git-sdk-64-minimal
|
||||||
|
uses: actions/download-artifact@v1
|
||||||
|
with:
|
||||||
|
name: git-sdk-64-minimal
|
||||||
|
path: ${{github.workspace}}/git-sdk-64-minimal/
|
||||||
- name: test
|
- name: test
|
||||||
shell: powershell
|
shell: powershell
|
||||||
run: |
|
run: |
|
||||||
|
@ -113,7 +132,19 @@ jobs:
|
||||||
- uses: actions/checkout@v1
|
- uses: actions/checkout@v1
|
||||||
- name: download git-sdk-64-minimal
|
- name: download git-sdk-64-minimal
|
||||||
shell: bash
|
shell: bash
|
||||||
run: a=git-sdk-64-minimal && mkdir -p $a && curl -# https://wingit.blob.core.windows.net/ci-artifacts/$a.tar.xz | tar -C $a -xJf -
|
run: |
|
||||||
|
## Get artifact
|
||||||
|
urlbase=https://dev.azure.com/git-for-windows/git/_apis/build/builds
|
||||||
|
id=$(curl "$urlbase?definitions=22&statusFilter=completed&resultFilter=succeeded&\$top=1" |
|
||||||
|
jq -r ".value[] | .id")
|
||||||
|
download_url="$(curl "$urlbase/$id/artifacts" |
|
||||||
|
jq -r '.value[] | select(.name == "git-sdk-64-minimal").resource.downloadUrl')"
|
||||||
|
curl --connect-timeout 10 --retry 5 --retry-delay 0 --retry-max-time 240 \
|
||||||
|
-o artifacts.zip "$download_url"
|
||||||
|
|
||||||
|
## Unzip and remove the artifact
|
||||||
|
unzip artifacts.zip
|
||||||
|
rm artifacts.zip
|
||||||
- name: generate Visual Studio solution
|
- name: generate Visual Studio solution
|
||||||
shell: powershell
|
shell: powershell
|
||||||
run: |
|
run: |
|
||||||
|
@ -153,15 +184,17 @@ jobs:
|
||||||
path: artifacts
|
path: artifacts
|
||||||
vs-test:
|
vs-test:
|
||||||
runs-on: windows-latest
|
runs-on: windows-latest
|
||||||
needs: [vs-build]
|
needs: [vs-build, windows-build]
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
nr: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
|
nr: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v1
|
- uses: actions/checkout@v1
|
||||||
- name: download git-64-portable
|
- name: download git-sdk-64-minimal
|
||||||
shell: bash
|
uses: actions/download-artifact@v1
|
||||||
run: a=git-64-portable && mkdir -p $a && curl -# https://wingit.blob.core.windows.net/ci-artifacts/$a.tar.xz | tar -C $a -xJf -
|
with:
|
||||||
|
name: git-sdk-64-minimal
|
||||||
|
path: ${{github.workspace}}/git-sdk-64-minimal/
|
||||||
- name: download build artifacts
|
- name: download build artifacts
|
||||||
uses: actions/download-artifact@v1
|
uses: actions/download-artifact@v1
|
||||||
with:
|
with:
|
||||||
|
@ -177,9 +210,9 @@ jobs:
|
||||||
NO_SVN_TESTS: 1
|
NO_SVN_TESTS: 1
|
||||||
GIT_TEST_SKIP_REBASE_P: 1
|
GIT_TEST_SKIP_REBASE_P: 1
|
||||||
run: |
|
run: |
|
||||||
& git-64-portable\git-cmd.exe --command=usr\bin\bash.exe -lc @"
|
& .\git-sdk-64-minimal\usr\bin\bash.exe -lc @"
|
||||||
# Let Git ignore the SDK and the test-cache
|
# Let Git ignore the SDK and the test-cache
|
||||||
printf '%s\n' /git-64-portable/ /test-cache/ >>.git/info/exclude
|
printf '%s\n' /git-sdk-64-minimal/ /test-cache/ >>.git/info/exclude
|
||||||
|
|
||||||
cd t &&
|
cd t &&
|
||||||
PATH=\"`$PWD/helper:`$PATH\" &&
|
PATH=\"`$PWD/helper:`$PATH\" &&
|
||||||
|
|
Загрузка…
Ссылка в новой задаче