From fb15780bdcf9dc36dcef37ebc615f44f931e6b81 Mon Sep 17 00:00:00 2001 From: skibitsky Date: Thu, 19 Dec 2024 09:03:53 +0200 Subject: [PATCH] Release workflow --- .github/workflows/dotnet-build-test.yml | 1 + .github/workflows/release.yml | 40 +++++++++++++++++++++++++ 2 files changed, 41 insertions(+) create mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/dotnet-build-test.yml b/.github/workflows/dotnet-build-test.yml index 395263b..7e10857 100644 --- a/.github/workflows/dotnet-build-test.yml +++ b/.github/workflows/dotnet-build-test.yml @@ -14,6 +14,7 @@ jobs: dotnet-version: [8.0.x] test-type: [unit-tests, integration-tests] runs-on: ${{ matrix.os }} + timeout-minutes: 30 steps: - uses: actions/checkout@v4 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..631a7ba --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,40 @@ +name: Release + +on: + release: + types: [published] + workflow_dispatch: + +jobs: + nuget: + runs-on: ubuntu-latest + timeout-minutes: 15 + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Setup .NET + uses: actions/setup-dotnet@v3 + with: + dotnet-version: | + 8.0.x + + - name: Build Release + run: dotnet build Reown.NoUnity.slnf -c Release --restore + + - name: Pack nugets + run: dotnet pack Reown.NoUnity.slnf -c Release --no-build --output . + + - name: List files + run: tree -L 3 + +# - name: Push to NuGet +# run: dotnet nuget push "*.nupkg" --api-key ${{secrets.nuget_api_key}} --source https://api.nuget.org/v3/index.json + + - name: Upload build artifacts + uses: actions/upload-artifact@v3 + with: + name: build-artifacts + path: | + **/bin/**/*.dll + !**/Tests/**/bin/**/*.dll \ No newline at end of file