Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
fe60acb24f | ||
|
|
5c36f07f41 |
9
.github/workflows/ci_release.yml
vendored
9
.github/workflows/ci_release.yml
vendored
@@ -44,10 +44,10 @@ jobs:
|
|||||||
create-release:
|
create-release:
|
||||||
name: Create Release
|
name: Create Release
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
if: startsWith(github.ref, 'refs/tags/v')
|
|
||||||
steps:
|
steps:
|
||||||
- name: Set meta data
|
- name: Set meta data
|
||||||
id: meta
|
id: meta
|
||||||
|
if: startsWith(github.ref, 'refs/tags/v')
|
||||||
# Writing to env with >> $GITHUB_ENV is an alternative
|
# Writing to env with >> $GITHUB_ENV is an alternative
|
||||||
run: |
|
run: |
|
||||||
echo "date=$(TZ=Europe/Zurich date +'%d.%m.%Y')" >> $GITHUB_OUTPUT
|
echo "date=$(TZ=Europe/Zurich date +'%d.%m.%Y')" >> $GITHUB_OUTPUT
|
||||||
@@ -58,6 +58,7 @@ jobs:
|
|||||||
TAG_NAME: ${{ github.ref_name }}
|
TAG_NAME: ${{ github.ref_name }}
|
||||||
- name: Create Release
|
- name: Create Release
|
||||||
id: create_release
|
id: create_release
|
||||||
|
if: startsWith(github.ref, 'refs/tags/v')
|
||||||
run: |
|
run: |
|
||||||
# https://docs.github.com/en/rest/releases/releases?apiVersion=2022-11-28#create-a-release
|
# https://docs.github.com/en/rest/releases/releases?apiVersion=2022-11-28#create-a-release
|
||||||
response=$(curl \
|
response=$(curl \
|
||||||
@@ -73,11 +74,13 @@ jobs:
|
|||||||
echo $(jq -r '.upload_url' <<< "$response") > release_url.txt
|
echo $(jq -r '.upload_url' <<< "$response") > release_url.txt
|
||||||
echo $(jq -r '.id' <<< "$response") > release_id.txt
|
echo $(jq -r '.id' <<< "$response") > release_id.txt
|
||||||
- name: Save Release URL File for publish
|
- name: Save Release URL File for publish
|
||||||
|
if: startsWith(github.ref, 'refs/tags/v')
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: release_url
|
name: release_url
|
||||||
path: release_url.txt
|
path: release_url.txt
|
||||||
- name: Save asset upload id for publish
|
- name: Save asset upload id for publish
|
||||||
|
if: startsWith(github.ref, 'refs/tags/v')
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: release_id
|
name: release_id
|
||||||
@@ -364,7 +367,7 @@ jobs:
|
|||||||
$asset_url
|
$asset_url
|
||||||
done
|
done
|
||||||
(cd assets/ && sha256sum * > ../sha256_hashes.txt)
|
(cd assets/ && sha256sum * > ../sha256_hashes.txt)
|
||||||
curl -X POST -H "Accept: application/vnd.github+json" -H "Content-Type: text/plain" -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" -H "X-GitHub-Api-Version: 2022-11-28" --show-error --data @sha256_hashes.txt ${{ steps.meta.outputs.upload_url }}=sha256_hashes.txt
|
curl -X POST -H "Accept: application/vnd.github+json" -H "Content-Type: text/plain" -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" -H "X-GitHub-Api-Version: 2022-11-28" --show-error --data-binary @sha256_hashes.txt ${{ steps.meta.outputs.upload_url }}=sha256_hashes.txt
|
||||||
|
|
||||||
(cd assets/ && sha512sum * > ../sha512_hashes.txt)
|
(cd assets/ && sha512sum * > ../sha512_hashes.txt)
|
||||||
curl -X POST -H "Accept: application/vnd.github+json" -H "Content-Type: text/plain" -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" -H "X-GitHub-Api-Version: 2022-11-28" --show-error --data @sha512_hashes.txt ${{ steps.meta.outputs.upload_url }}=sha512_hashes.txt
|
curl -X POST -H "Accept: application/vnd.github+json" -H "Content-Type: text/plain" -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" -H "X-GitHub-Api-Version: 2022-11-28" --show-error --data-binary @sha512_hashes.txt ${{ steps.meta.outputs.upload_url }}=sha512_hashes.txt
|
||||||
|
|||||||
Reference in New Issue
Block a user