diff --git a/.github/workflows/buildandtest.yml b/.github/workflows/buildandtest.yml deleted file mode 100644 index 0d1f9b24..00000000 --- a/.github/workflows/buildandtest.yml +++ /dev/null @@ -1,32 +0,0 @@ -name: Build and Test -on: - # Testing - run for any PRs. - pull_request: - branches: - - main - -jobs: - - # Build, test and publish (if this is a push/merge). - build-and-test: - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v4 - - - name: Setup .NET 8.0 - uses: actions/setup-dotnet@v3 - with: - dotnet-version: 8.0.x - - - name: Install dependencies - run: dotnet restore - - - name: Build - run: dotnet build --configuration Release --no-restore - - - name: Test - run: dotnet test test/Soenneker.Utils.MemoryStream.Tests.csproj --no-restore --verbosity normal - - - name: Pack - run: dotnet pack --no-build --configuration Release --output . diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml deleted file mode 100644 index ad79e428..00000000 --- a/.github/workflows/publish.yml +++ /dev/null @@ -1,59 +0,0 @@ -name: Publish -on: - push: - branches: - - main - - # Publish `v1.2.3` tags as releases. - tags: - - v* -jobs: - - # Build, test and publish (if this is a push/merge). - publish-build-and-test: - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v4 - - - name: Setup .NET 8.0 - uses: actions/setup-dotnet@v3 - with: - dotnet-version: 8.0.x - - - name: Install dependencies - run: dotnet restore - - - name: Build - run: dotnet build --configuration Release --no-restore - - - name: Test - run: dotnet test test/Soenneker.Utils.MemoryStream.Tests.csproj --no-restore --verbosity normal - - publish-package: - needs: publish-build-and-test - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - - name: Setting up build version - run: | - version=$(($GITHUB_RUN_NUMBER)) - echo "BUILD_VERSION=2.0.$version" >> ${GITHUB_ENV} - - - name: Setup .NET Core 8.0 - uses: actions/setup-dotnet@v3 - with: - dotnet-version: 8.0.x - - - name: Install dependencies - run: dotnet restore - - - name: Build - run: dotnet build --configuration Release --no-restore - - - name: Pack - run: dotnet pack --no-build --configuration Release --output . - - - name: Publish to nuGet - run: dotnet nuget push **\*.nupkg --source 'https://api.nuget.org/v3/index.json' --api-key ${{secrets.NUGET_API_KEY}} --skip-duplicate