|
4 | 4 | workflow_dispatch:
|
5 | 5 | inputs:
|
6 | 6 | name:
|
7 |
| - description: "When you press run workflow, the nuget package will be published." |
8 |
| - default: "I understand." |
| 7 | + description: 'When you press run workflow, the nuget package will be published.' |
| 8 | + default: 'I understand.' |
9 | 9 | jobs:
|
10 | 10 | build:
|
11 |
| - |
12 | 11 | runs-on: ubuntu-latest
|
13 | 12 | steps:
|
14 |
| - - uses: actions/checkout@v3 |
15 |
| - - name: Setup .NET |
16 |
| - uses: actions/setup-dotnet@v3 |
17 |
| - with: |
18 |
| - dotnet-version: | |
19 |
| - 8.0.x |
20 |
| - 7.0.x |
21 |
| - 6.0.x |
22 |
| - - name: Display dotnet version |
23 |
| - run: dotnet --version |
24 |
| - - name: Restore dependencies |
25 |
| - working-directory: ./src |
26 |
| - run: dotnet restore |
27 |
| - - name: Build |
28 |
| - run: dotnet build --configuration Release --no-restore |
29 |
| - working-directory: ./src |
30 |
| - - name: Test |
31 |
| - run: dotnet test --no-build --configuration Release --verbosity normal |
32 |
| - working-directory: ./src |
33 |
| - - name: Publish the package to nuget.org |
34 |
| - run: dotnet nuget push ZoneTree/bin/Release/*.nupkg -k $NUGET_AUTH_TOKEN -s https://api.nuget.org/v3/index.json |
35 |
| - env: |
36 |
| - NUGET_AUTH_TOKEN: ${{ secrets.NUGET_TOKEN }} |
37 |
| - working-directory: ./src |
| 13 | + - uses: actions/checkout@v3 |
| 14 | + - name: Setup .NET |
| 15 | + uses: actions/setup-dotnet@v3 |
| 16 | + with: |
| 17 | + dotnet-version: | |
| 18 | + 9.0.x |
| 19 | + 8.0.x |
| 20 | + 7.0.x |
| 21 | + 6.0.x |
| 22 | + - name: Display dotnet version |
| 23 | + run: dotnet --version |
| 24 | + - name: Restore dependencies |
| 25 | + working-directory: ./src |
| 26 | + run: dotnet restore |
| 27 | + - name: Build |
| 28 | + run: dotnet build --configuration Release --no-restore |
| 29 | + working-directory: ./src |
| 30 | + - name: Test |
| 31 | + run: dotnet test --no-build --configuration Release --verbosity normal |
| 32 | + working-directory: ./src |
| 33 | + - name: Publish the package to nuget.org |
| 34 | + run: dotnet nuget push ZoneTree/bin/Release/*.nupkg -k $NUGET_AUTH_TOKEN -s https://api.nuget.org/v3/index.json |
| 35 | + env: |
| 36 | + NUGET_AUTH_TOKEN: ${{ secrets.NUGET_TOKEN }} |
| 37 | + working-directory: ./src |
0 commit comments