|
1 | 1 | name: Publish Package |
2 | 2 |
|
3 | 3 | env: |
4 | | - Version: 0.1.0 |
5 | | - NUGET_API_KEY: ${{secrets.NUGET_API_KEY}} |
| 4 | + Version: 0.1.0 |
| 5 | + NUGET_API_KEY: ${{secrets.NUGET_API_KEY}} |
6 | 6 |
|
7 | 7 | on: |
8 | | - push: |
9 | | - branches: |
10 | | - - master |
| 8 | + push: |
| 9 | + branches: |
| 10 | + - master |
11 | 11 |
|
12 | 12 | jobs: |
13 | | - publish-and-deploy: |
14 | | - runs-on: ubuntu-latest |
15 | | - if: github.repository_owner == 'ant-design-blazor' |
16 | | - |
17 | | - steps: |
18 | | - - name: Checkout 🛎️ |
19 | | - uses: actions/checkout@v2 |
20 | | - with: |
21 | | - persist-credentials: false |
22 | | - |
23 | | - - name: Setup .NET Core |
24 | | - uses: actions/setup-dotnet@v1 |
25 | | - with: |
26 | | - dotnet-version: 5.0.100 |
27 | | - |
28 | | - - uses: actions/setup-node@v1 |
29 | | - with: |
30 | | - node-version: '10.x' |
31 | | - |
32 | | - - name: Package Nightly Nuget 📦 |
33 | | - run: | |
34 | | - npm i |
35 | | - SUFFIX=`date "+%y%m%d%H%M%S"` |
36 | | - dotnet build |
37 | | - dotnet pack src/layout/src/AntDesign.ProLayout.csproj /p:PackageVersion=$Version-nightly-${SUFFIX} -c Release -o publish |
38 | | -
|
39 | | - - name: Publish to Nuget ✔ |
40 | | - run: | |
41 | | - dotnet nuget push publish/*.nupkg -s https://api.nuget.org/v3/index.json -k $NUGET_API_KEY --skip-duplicate |
| 13 | + publish-and-deploy: |
| 14 | + runs-on: ubuntu-latest |
| 15 | + if: github.repository_owner == 'ant-design-blazor' |
| 16 | + |
| 17 | + steps: |
| 18 | + - name: Checkout 🛎️ |
| 19 | + uses: actions/checkout@v2 |
| 20 | + with: |
| 21 | + persist-credentials: false |
| 22 | + |
| 23 | + - name: Setup .NET Core |
| 24 | + uses: actions/setup-dotnet@v1 |
| 25 | + with: |
| 26 | + dotnet-version: 5.0.100 |
| 27 | + |
| 28 | + - uses: actions/setup-dotnet@v1 |
| 29 | + with: |
| 30 | + dotnet-version: 6.0.101 |
| 31 | + |
| 32 | + - uses: actions/setup-node@v1 |
| 33 | + with: |
| 34 | + node-version: '10.x' |
| 35 | + |
| 36 | + - name: Package Nightly Nuget 📦 |
| 37 | + run: | |
| 38 | + npm i |
| 39 | + SUFFIX=`date "+%y%m%d%H%M%S"` |
| 40 | + dotnet build |
| 41 | + dotnet pack src/layout/src/AntDesign.ProLayout.csproj /p:PackageVersion=$Version-nightly-${SUFFIX} -c Release -o publish |
| 42 | +
|
| 43 | + - name: Publish to Nuget ✔ |
| 44 | + run: | |
| 45 | + dotnet nuget push publish/*.nupkg -s https://api.nuget.org/v3/index.json -k $NUGET_API_KEY --skip-duplicate |
0 commit comments