Add RootHandler capabilities (#66) #37
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: CD-Build | |
| # Note: this is a mixture of windows build and linux deployments | |
| on: | |
| push: | |
| # Runs on all branches so they share a github.run_number increment | |
| branches: [ stable ] | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: 8.0.x | |
| - name: Restore dependencies | |
| run: dotnet restore src/MinimalCli.sln | |
| # build solution here instead of project | |
| - name: Build Minimal Command Line | |
| run: dotnet build src/MinimalCli.sln -c Release --no-restore | |
| # packs all nuget packages at once | |
| - name: Pack Minimal Command Line Nuget Alpha | |
| run: dotnet pack src/MinimalCli/MinimalCli.csproj -p:PackageVersion=2.0.0.${{github.run_number}}-alpha -o ./packages | |
| - name: Pack Minimal Command Line Nuget | |
| run: dotnet pack src/MinimalCli/MinimalCli.csproj -p:PackageVersion=2.0.0.${{github.run_number}} -o ./packages | |
| - name: Publish Minimal Command Line Artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: Nugets | |
| path: packages/*.nupkg | |
| integration: | |
| needs: build | |
| name: Deploy Nuget-alpha packages | |
| environment: | |
| name: Integration | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Download nugets | |
| uses: actions/download-artifact@v4.1.7 | |
| with: | |
| name: Nugets | |
| - name: Display structure of downloaded files | |
| run: ls -R | |
| - name: Push Minimal Command Line Nuget | |
| run: dotnet nuget push ./MinimalCli.2.0.0.${{github.run_number}}-alpha.nupkg --api-key ${{secrets.NUGETKEY}} --source https://api.nuget.org/v3/index.json | |
| production: | |
| needs: integration | |
| name: Deploy Nuget packages to production | |
| environment: | |
| name: Production | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Download nugets | |
| uses: actions/download-artifact@v4.1.7 | |
| with: | |
| name: Nugets | |
| - name: Push Minimal Command Line Nuget | |
| run: dotnet nuget push ./MinimalCli.2.0.0.${{github.run_number}}.nupkg --api-key ${{secrets.NUGETKEY}} --source https://api.nuget.org/v3/index.json |