diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c86636b..65faec4 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -6,7 +6,7 @@ on: - master jobs: - update_release_draft: + build: runs-on: ubuntu-latest steps: # Checkout @@ -39,4 +39,51 @@ jobs: - name: upload artifacts uses: actions/upload-artifact@v3 with: - path: dynamicpixels-unity.zip \ No newline at end of file + path: dynamicpixels-unity.zip + + - name: Create Release + id: create_release + uses: actions/create-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token + with: + tag_name: ${{ github.ref }} + release_name: Release ${{ github.ref }} + body: | + Changes in this Release + - First Change + - Second Change + draft: false + prerelease: false + + release: + name: Create Release + needs: build + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + + - name: Download artifact + uses: actions/download-artifact@v3 + with: + name: Unity Package + + - name: Create GitHub Release + id: create_release + uses: actions/create-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + tag_name: ${{ github.ref }} + release_name: Release ${{ github.ref }} + draft: false + prerelease: false + + - name: Upload Release Asset + uses: actions/upload-release-asset@v1 + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + asset_path: ./dynamicpixels-unity.zip + asset_name: dynamicpixels-unity.zip + asset_content_type: application/zip \ No newline at end of file