waforth/.github/workflows/publish-standalone.yml

35 lines
1,017 B
YAML
Raw Normal View History

2022-05-26 12:07:41 +02:00
name: Publish Standalone
on:
release:
types: [created]
jobs:
build:
uses: ./.github/workflows/build.yml
publish-standalone:
needs: build
strategy:
matrix:
os: [macos-latest, ubuntu-18.04]
2022-05-26 12:07:41 +02:00
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- uses: ./.github/actions/setup
2022-06-10 20:22:57 +02:00
- run: make -C src/standalone install-deps package
- run: make -C src/standalone check
2022-05-26 17:00:38 +02:00
- name: "Upload artifacts"
run: |
2022-05-26 15:34:04 +02:00
for f in src/standalone/waforth-*.tgz; do
2022-05-26 17:00:38 +02:00
curl --fail \
2022-05-26 15:34:04 +02:00
-H "Authorization: token $GITHUB_TOKEN" \
-H "Content-Type: $(file -b --mime-type $f)" \
--data-binary @$f \
2022-05-26 17:00:38 +02:00
"$RELEASE_ASSETS_UPLOAD_URL?name=$(basename $f)"
2022-05-26 15:34:04 +02:00
done
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2022-05-26 17:00:38 +02:00
RELEASE_ASSETS_UPLOAD_URL: https://uploads.github.com/repos/${{ github.event.repository.full_name}}/releases/${{ github.event.release.id }}/assets
2022-05-26 15:34:04 +02:00