File tree Expand file tree Collapse file tree 1 file changed +45
-6
lines changed Expand file tree Collapse file tree 1 file changed +45
-6
lines changed Original file line number Diff line number Diff line change 1
- name : CD-NuGet
1
+ name : Release
2
+
3
+
2
4
3
5
on :
4
6
push :
7
+ # Sequence of patterns matched against refs/tags
5
8
tags :
9
+ - ' v*.*.*'
10
+ - ' v*.*.*-rc*'
6
11
- ' [0-9]+.[0-9]+.[0-9]+'
7
12
- ' [0-9]+.[0-9]+.[0-9]+-rc[0-9]+'
8
-
13
+
9
14
jobs :
10
15
build :
11
16
runs-on : ubuntu-latest
19
24
with :
20
25
dotnet-version : 6.0.x
21
26
27
+ - name : Restore dependencies
28
+ run : dotnet restore
29
+
30
+ - name : Build
31
+ id : build-project
32
+ run : dotnet build ./Source/FikaAmazonAPI/FikaAmazonAPI.csproj --configuration Release --no-restore
33
+
34
+
22
35
- name : Pack
36
+ id : pack-prohject
23
37
run : |
24
- dotnet pack --configuration Release
25
- - name : Deploy
26
- run : |
27
- dotnet nuget push source/FikaAmazonAPI/bin/Release/*.nupkg -s nuget.org -k ${{ secrets.NUGET_TOKEN }}
38
+ dotnet pack ./Source/FikaAmazonAPI/FikaAmazonAPI.csproj --configuration Release
39
+
40
+ - name : PushNuget
41
+ run : dotnet nuget push "**/*.nupkg" --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_TOKEN }} --skip-duplicate
42
+
43
+
44
+ - name : Add github package source
45
+ run : nuget sources Add -Name "github" -Source https://nuget.pkg.github.com/${{github.repository_owner}}/index.json -UserName ${{github.repository_owner}} -Password ${{ secrets.USERGIHUB_TOKEN }}
46
+
47
+
48
+ - name : Push to GitHub Packages
49
+ run : dotnet nuget push "**/*.nupkg" --skip-duplicate --source https://nuget.pkg.github.com/${{github.repository_owner}}/index.json --api-key ${GITHUB_TOKEN}
50
+ env :
51
+ GITHUB_TOKEN : ${{ secrets.USERGIHUB_TOKEN }}
52
+
53
+ - name : Create Release
54
+ id : create_release
55
+ uses : actions/create-release@latest
56
+ env :
57
+ GITHUB_TOKEN : ${{ secrets.USERGIHUB_TOKEN }}
58
+ with :
59
+ tag_name : ${{ github.ref }}
60
+ release_name : Release ${{ github.ref }}
61
+ body : TODO
62
+ draft : false
63
+ prerelease : false
64
+
65
+
66
+
You can’t perform that action at this time.
0 commit comments