Modernize ASP.NET Core samples #457
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: Build | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| jobs: | |
| build: | |
| runs-on: ubuntu-22.04 | |
| env: | |
| DOTNET_NOLOGO: true | |
| steps: | |
| - name: Check out our repo | |
| uses: actions/checkout@v3 | |
| with: | |
| submodules: true | |
| # Build with .NET 8.0 SDK | |
| # Test with .NET 6.0 and 8.0 | |
| - name: Setup .NET 6.0 and 8.0 | |
| uses: actions/setup-dotnet@v3 | |
| with: | |
| dotnet-version: | | |
| 8.0.x | |
| 6.0.x | |
| - name: Build | |
| run: | | |
| dotnet build | |
| dotnet test | |
| # Pack production packages to validate compatibility | |
| dotnet pack -p:ContinuousIntegrationBuild=true |