1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-12-22 07:14:47 -05:00

build: upload canary releases to GCS (#8441)

This commit is contained in:
Luca Casonato 2020-11-23 18:06:47 +01:00 committed by GitHub
parent bc79d55649
commit 46850918e7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -101,6 +101,32 @@ jobs:
Select-Object -Skip 1 |
ForEach-Object { Move-Item "$_" "$_.disabled" }
- name: Setup gcloud (unix)
if: |
runner.os != 'Windows' &&
matrix.kind == 'test_release' &&
github.repository == 'denoland/deno' &&
github.ref == 'refs/heads/master'
uses: google-github-actions/setup-gcloud@master
with:
project_id: denoland
service_account_key: ${{ secrets.GCP_SA_KEY }}
export_default_credentials: true
- name: Setup gcloud (windows)
if: |
runner.os == 'Windows' &&
matrix.kind == 'test_release' &&
github.repository == 'denoland/deno' &&
github.ref == 'refs/heads/master'
uses: google-github-actions/setup-gcloud@master
env:
CLOUDSDK_PYTHON: ${{env.pythonLocation}}\python.exe
with:
project_id: denoland
service_account_key: ${{ secrets.GCP_SA_KEY }}
export_default_credentials: true
- name: Log versions
run: |
node -v
@ -186,7 +212,32 @@ jobs:
run: |
Compress-Archive -CompressionLevel Optimal -Force -Path target/release/deno.exe -DestinationPath target/release/deno-x86_64-pc-windows-msvc.zip
- name: Release
- name: Upload canary (unix)
if: |
runner.os != 'Windows' &&
matrix.kind == 'test_release' &&
github.repository == 'denoland/deno' &&
github.ref == 'refs/heads/master'
run: |
gsutil cp ./target/release/*.zip gs://dl.deno.land/canary/$(git rev-parse HEAD)/
echo $(git rev-parse HEAD) > canary-latest.txt
gsutil cp canary-latest.txt gs://dl.deno.land/canary-latest.txt
- name: Upload canary (windows)
if: |
runner.os == 'Windows' &&
matrix.kind == 'test_release' &&
github.repository == 'denoland/deno' &&
github.ref == 'refs/heads/master'
env:
CLOUDSDK_PYTHON: ${{env.pythonLocation}}\python.exe
shell: bash
run: |
gsutil cp ./target/release/*.zip gs://dl.deno.land/canary/$(git rev-parse HEAD)/
echo $(git rev-parse HEAD) > canary-latest.txt
gsutil cp canary-latest.txt gs://dl.deno.land/canary-latest.txt
- name: Release stable
uses: softprops/action-gh-release@v1
if: |
matrix.kind == 'test_release' &&