diff options
author | Ryan Mast <nightlark@users.noreply.github.com> | 2019-10-31 05:30:12 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-10-31 05:30:12 (GMT) |
commit | da2dad895393d39bcc36b593edb6eb89e7cb5c0a (patch) | |
tree | 713bdbe86709ac57559993d5e098d7b565df3163 /.github | |
parent | 49a14a8b7c7926628261b2a48a807745cffd0f56 (diff) | |
download | Ninja-da2dad895393d39bcc36b593edb6eb89e7cb5c0a.zip Ninja-da2dad895393d39bcc36b593edb6eb89e7cb5c0a.tar.gz Ninja-da2dad895393d39bcc36b593edb6eb89e7cb5c0a.tar.bz2 |
Upload ninja binary to published releases
Diffstat (limited to '.github')
-rw-r--r-- | .github/workflows/release-ninja-binaries.yml | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/.github/workflows/release-ninja-binaries.yml b/.github/workflows/release-ninja-binaries.yml index b241c53..e818c86 100644 --- a/.github/workflows/release-ninja-binaries.yml +++ b/.github/workflows/release-ninja-binaries.yml @@ -1,6 +1,9 @@ name: Release Ninja Binaries -on: [push] +on: + push: + release: + types: published jobs: build: @@ -37,7 +40,7 @@ jobs: cmake -DCMAKE_BUILD_TYPE=Release .. cmake --build . --parallel --config Release --target ninja - - name: Create artifact + - name: Create ninja archive shell: bash env: ZIP_NAME: ${{ matrix.zip_name }} @@ -52,4 +55,13 @@ jobs: name: ninja-binary-archives path: artifact - + - name: Upload release asset + if: github.event.action == 'published' + uses: actions/upload-release-asset@v1.0.1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ github.event.release.upload_url }} + asset_path: ./artifact/${{ matrix.zip_name }}.zip + asset_name: ${{ matrix.zip_name }}.zip + asset_content_type: application/zip |