From 4ceaaeed6e76652be6de09faa6d2b3cfe111beba Mon Sep 17 00:00:00 2001 From: Llywelwyn <82828093+Llywelwyn@users.noreply.github.com> Date: Mon, 25 Jul 2022 21:29:37 +0100 Subject: [PATCH] deploying via workflow --- .github/workflows/dotnet-build-test.yml | 30 +++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/.github/workflows/dotnet-build-test.yml b/.github/workflows/dotnet-build-test.yml index 1511ab8..0c5fec0 100644 --- a/.github/workflows/dotnet-build-test.yml +++ b/.github/workflows/dotnet-build-test.yml @@ -31,3 +31,33 @@ jobs: path: | CharacterRecordsGenerator/bin/Release/*.exe CharacterRecordsGenerator/bin/Release/*.dll + deploy: + name: Create release + runs-on: ubuntu-latest + if: startsWith(github.ref, 'refs/tags/v') + needs: build + steps: + - name: Checkout repository + uses: actions/checkout@v3 + - name: Create release + id: create_release + uses: actions/create-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + tag_name: ${{ github.ref }} + release_name: ${{ github.ref }} + draft: false + prerelease: false + - uses: actions/download-artifact@v3 + with: + name: character-records-generator + - name: Upload character-records-generator + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + asset_path: ./character-records-generator.zip + asset_name: character-records-generator.zip + asset_content_type: application/zip