diff --git a/.github/workflows/build_and_test.yml b/.github/workflows/build_and_test.yml index ae6b7e63..1c9e0a43 100644 --- a/.github/workflows/build_and_test.yml +++ b/.github/workflows/build_and_test.yml @@ -1,65 +1,65 @@ -# This workflow will build a .NET project -# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net +# # This workflow will build a .NET project +# # For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net -name: build_and_test +# name: build_and_test -on: - push: - branches: [ "master" ] - pull_request: - branches: [ "master" ] +# on: +# push: +# branches: [ "master" ] +# pull_request: +# branches: [ "master" ] -jobs: - windows: +# jobs: +# windows: - runs-on: windows-latest +# runs-on: windows-latest - steps: - - uses: actions/checkout@v3 - - name: Setup .NET 6 - uses: actions/setup-dotnet@v3 - with: - dotnet-version: 6.0.x - - name: Restore dependencies - run: dotnet restore - - name: Build CPU version - run: dotnet build --no-restore -# - name: Test CPU version -# run: dotnet test --no-build --verbosity normal - - name: uninstall redist cpu for unit tests - run: dotnet remove helpers/Tensorflow.UnitTest.RedistHolder package SciSharp.TensorFlow.Redist - - name: install redist gpu for unit tests - run: dotnet add helpers/Tensorflow.UnitTest.RedistHolder package SciSharp.TensorFlow.Redist-Windows-GPU - - name: Restore dependencies - run: dotnet restore - - name: Build GPU version - run: dotnet build --no-restore -# - name: Test GPU version -# run: dotnet test --no-build --verbosity normal +# steps: +# - uses: actions/checkout@v3 +# - name: Setup .NET 6 +# uses: actions/setup-dotnet@v3 +# with: +# dotnet-version: 6.0.x +# - name: Restore dependencies +# run: dotnet restore +# - name: Build CPU version +# run: dotnet build --no-restore +# # - name: Test CPU version +# # run: dotnet test --no-build --verbosity normal +# - name: uninstall redist cpu for unit tests +# run: dotnet remove helpers/Tensorflow.UnitTest.RedistHolder package SciSharp.TensorFlow.Redist +# - name: install redist gpu for unit tests +# run: dotnet add helpers/Tensorflow.UnitTest.RedistHolder package SciSharp.TensorFlow.Redist-Windows-GPU +# - name: Restore dependencies +# run: dotnet restore +# - name: Build GPU version +# run: dotnet build --no-restore +# # - name: Test GPU version +# # run: dotnet test --no-build --verbosity normal - linux: +# linux: - runs-on: ubuntu-latest +# runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - name: Setup .NET - uses: actions/setup-dotnet@v3 - with: - dotnet-version: 6.0.x - - name: Restore dependencies - run: dotnet restore - - name: Build CPU version - run: dotnet build --no-restore -# - name: Test CPU version -# run: dotnet test --no-build --verbosity normal - - name: uninstall redist cpu for unit tests - run: dotnet remove helpers/Tensorflow.UnitTest.RedistHolder package SciSharp.TensorFlow.Redist - - name: install redist gpu for unit tests - run: dotnet add helpers/Tensorflow.UnitTest.RedistHolder package SciSharp.TensorFlow.Redist-Linux-GPU - - name: Restore dependencies - run: dotnet restore - - name: Build GPU version - run: dotnet build --no-restore -# - name: Test GPU version -# run: dotnet test --no-build --verbosity normal +# steps: +# - uses: actions/checkout@v3 +# - name: Setup .NET +# uses: actions/setup-dotnet@v3 +# with: +# dotnet-version: 6.0.x +# - name: Restore dependencies +# run: dotnet restore +# - name: Build CPU version +# run: dotnet build --no-restore +# # - name: Test CPU version +# # run: dotnet test --no-build --verbosity normal +# - name: uninstall redist cpu for unit tests +# run: dotnet remove helpers/Tensorflow.UnitTest.RedistHolder package SciSharp.TensorFlow.Redist +# - name: install redist gpu for unit tests +# run: dotnet add helpers/Tensorflow.UnitTest.RedistHolder package SciSharp.TensorFlow.Redist-Linux-GPU +# - name: Restore dependencies +# run: dotnet restore +# - name: Build GPU version +# run: dotnet build --no-restore +# # - name: Test GPU version +# # run: dotnet test --no-build --verbosity normal diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 24bdee05..3acab001 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,10 +1,14 @@ -name: release +name: auto-release on: - workflow_run: - workflows: ["build_and_test"] - types: - - completed + # workflow_run: + # workflows: ["build_and_test"] + # types: + # - completed + push: + branches: [ "master" ] + pull_request: + branches: [ "master" ] env: MYGET_API_TOKEN: ${{ SECRETS.RINNE_MYGET_KEY }} @@ -12,6 +16,7 @@ env: jobs: build: + if: ${{ github.event.label.name == 'auto-release'}} runs-on: windows-latest steps: