Bump System.CommandLine from 2.0.0-beta4.22272.1 to 2.0.1 #643
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: .NET Core | |
| on: | |
| push: | |
| branches: [ master ] | |
| # Sequence of patterns matched against refs/tags | |
| tags: | |
| - 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10 | |
| paths-ignore: | |
| - 'README.md' | |
| pull_request: | |
| branches: [ master ] | |
| workflow_dispatch: | |
| defaults: | |
| run: | |
| shell: pwsh | |
| env: | |
| configuration: Release | |
| baseVersion: 1.3.0 | |
| preRelease: true | |
| jobs: | |
| build: | |
| runs-on: windows-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| - name: Set Version | |
| run: | | |
| if ("${{ github.ref }}".startsWith("refs/tags/v")) { | |
| $tagVersion = "${{ github.ref }}".substring(11) | |
| echo "buildVersion=$tagVersion.${{ github.run_number }}" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append | |
| echo "nugetVersion=$tagVersion" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append | |
| echo "preRelease=false" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append | |
| } else { | |
| echo "buildVersion=${{ env.baseVersion }}.${{ github.run_number }}" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append | |
| echo "nugetVersion=${{ env.baseVersion }}-ci${{ github.run_number }}" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append | |
| } | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v5 | |
| with: | |
| dotnet-version: | | |
| 8.x | |
| 9.x | |
| env: | |
| NUGET_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}} | |
| - name: Install dependencies | |
| run: dotnet restore | |
| - name: Build | |
| run: dotnet build -p:Version=${{ env.buildVersion }} -p:ContinuousIntegrationBuild=True --configuration ${{ env.configuration }} --no-restore | |
| - name: Minimize all windows | |
| run: (New-Object -ComObject "Shell.Application").minimizeall() | |
| - name: Test net8.0 | |
| run: dotnet test --framework net8.0-windows --no-build --verbosity normal --configuration ${{ env.configuration }} --blame-crash --blame-crash-collect-always --blame-hang --blame-hang-timeout 5m | |
| - name: Test net9.0 | |
| run: dotnet test --framework net9.0-windows --no-build --verbosity normal --configuration ${{ env.configuration }} --blame-crash --blame-crash-collect-always --blame-hang --blame-hang-timeout 5m | |
| - name: Test Logs | |
| if: ${{ always() }} | |
| uses: actions/upload-artifact@v6 | |
| with: | |
| name: Test Logs | |
| path: ${{ github.workspace }}\XAMLTest.Tests\bin\${{ env.configuration }}\**\*.log | |
| - name: Upload Crash Dumps | |
| if: ${{ always() }} | |
| uses: actions/upload-artifact@v6 | |
| with: | |
| name: Crash Dumps | |
| path: ${{ github.workspace }}\XAMLTest.Tests\TestResults\**\*.dmp | |
| - name: Upload Screenshots | |
| if: ${{ always() }} | |
| uses: actions/upload-artifact@v6 | |
| with: | |
| name: Test Images | |
| path: ${{ github.workspace }}\XAMLTest.Tests\bin\${{ env.configuration }}\**\Screenshots | |
| - name: Pack | |
| run: dotnet pack -p:PackageVersion=${{ env.nugetVersion }} --configuration ${{ env.configuration }} --no-build | |
| - name: Upload Artifacts | |
| if: ${{ github.event_name != 'pull_request' }} | |
| uses: actions/upload-artifact@v6 | |
| with: | |
| name: NuGet | |
| path: ${{ github.workspace }}\XAMLTest\bin\${{ env.configuration }}\XAMLTest.${{ env.nugetVersion }}*nupkg | |
| - name: Push NuGet | |
| if: ${{ github.event_name != 'pull_request' }} | |
| run: dotnet nuget push ${{ github.workspace }}\XAMLTest\bin\${{ env.configuration }}\XAMLTest.${{ env.nugetVersion }}.nupkg --source https://api.nuget.org/v3/index.json -k ${{ secrets.NUGET_API_KEY }} --skip-duplicate | |
| automerge: | |
| needs: build | |
| runs-on: ubuntu-latest | |
| permissions: | |
| pull-requests: write | |
| contents: write | |
| steps: | |
| - uses: fastify/github-action-merge-dependabot@v3.11.2 |