-
Notifications
You must be signed in to change notification settings - Fork 0
39 lines (35 loc) · 1.71 KB
/
dotnet.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: .NET
on:
push:
tags:
- 'v*'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: 建立.netcore环境
uses: actions/setup-dotnet@v1
with:
dotnet-version: 6.0.407
- name: 安装依赖
run: dotnet restore
- name: 构建
run: dotnet build --configuration Release --no-restore
- name: 添加github仓库
run: |
nuget sources add -name github -Source https://nuget.pkg.github.com/my6521/index.json -Username my6521 -Password ${{ secrets.GITHUBTOKEN }}
- name: 安装nuget
uses: nuget/setup-nuget@v1
with:
nuget-version: '5.x'
- name: 发布生成包到github和nuget
run: |
nuget push ./src/WWB.Paylink.BaoFooPay/bin/Release/*.nupkg -Source https://api.nuget.org/v3/index.json -SkipDuplicate -ApiKey ${{ secrets.NUGETKEY }}
nuget push ./src/WWB.Paylink.BaoFooPay/bin/Release/*.nupkg -Source github -SkipDuplicate
nuget push ./src/WWB.Paylink.BaoFooTransfer/bin/Release/*.nupkg -Source https://api.nuget.org/v3/index.json -SkipDuplicate -ApiKey ${{ secrets.NUGETKEY }}
nuget push ./src/WWB.Paylink.BaoFooTransfer/bin/Release/*.nupkg -Source github -SkipDuplicate
nuget push ./src/WWB.Paylink.Utility/bin/Release/*.nupkg -Source https://api.nuget.org/v3/index.json -SkipDuplicate -ApiKey ${{ secrets.NUGETKEY }}
nuget push ./src/WWB.Paylink.Utility/bin/Release/*.nupkg -Source github -SkipDuplicate
nuget push ./src/WWB.Paylink.JoinPay/bin/Release/*.nupkg -Source https://api.nuget.org/v3/index.json -SkipDuplicate -ApiKey ${{ secrets.NUGETKEY }}
nuget push ./src/WWB.Paylink.JoinPay/bin/Release/*.nupkg -Source github -SkipDuplicate