map release id

This commit is contained in:
Jonathan Shook 2020-03-17 08:07:22 -05:00 committed by GitHub
parent fb9c0ef02d
commit 3c78e6b853
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -116,6 +116,10 @@ jobs:
with:
name: guidebook
path: guidebook
- name: find latest release
run: |
LATEST_GH_RELEASE_ID=$(curl --silent "https://api.github.com/repos/$1/releases/latest" | jq -r .id)
echo "::set-env name=LATEST_GH_RELEASE_ID::${LATEST_GH_RELEASE_ID}"
- name: upload jar
uses: actions/upload-release-asset@v1
env:
@ -124,7 +128,7 @@ jobs:
asset_path: nb/target/nb.jar
asset_name: nb.jar
asset_content_type: application/octet-stream
upload_url: https://uploads.github.com/repos/nosqlbench/nosqlbench/releases/${RELEASE_TAGNAME}/assets?name=nb.jar
upload_url: https://uploads.github.com/repos/nosqlbench/nosqlbench/releases/${LATEST_GH_RELEASE_ID}/assets?name=nb.jar
- name: upload binary
uses: actions/upload-release-asset@v1
env:
@ -133,7 +137,7 @@ jobs:
asset_path: nb/target/nb
asset_name: nb
asset_content_type: application/octet-stream
upload_url: https://uploads.github.com/repos/nosqlbench/nosqlbench/releases/${RELEASE_TAGNAME}/assets?name=nb
upload_url: https://uploads.github.com/repos/nosqlbench/nosqlbench/releases/${LATEST_GH_RELEASE_ID}/assets?name=nb
docs:
needs: release