@@ -23,109 +23,3 @@ jobs:
23
23
with :
24
24
name : " WEventViewer-win-x64"
25
25
path : " dist/publish/Release/${{matrix.rid}}/WEventViewer-${{matrix.rid}}.zip"
26
- release :
27
- runs-on : " windows-latest"
28
- needs : ["build"]
29
- if : startsWith(github.ref, 'refs/tags/')
30
- steps :
31
- - uses : actions/checkout@v1
32
- - name : Setup .NET Core
33
- uses : actions/setup-dotnet@v3
34
- with :
35
- dotnet-version : |
36
- 8.0.100
37
- - name : restore dotnet tools
38
- run : dotnet tool restore
39
- - name : downloading nuget package
40
- uses : actions/download-artifact@v1
41
- with :
42
- name : " nupkg-win-x64"
43
- path : nupkg
44
- - name : downloading win-x64 binary
45
- uses : actions/download-artifact@v1
46
- with :
47
- name : " bin-win-x64"
48
- path : win-x64
49
- - name : downloading osx-x64 binary
50
- uses : actions/download-artifact@v1
51
- with :
52
- name : " bin-osx-x64"
53
- path : osx-x64
54
- - name : downloading linux-x64 binary
55
- uses : actions/download-artifact@v1
56
- with :
57
- name : " bin-linux-x64"
58
- path : linux-x64
59
- - name : create github release
60
- uses : actions/create-release@v1
61
- id : create_release
62
- env :
63
- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
64
- with :
65
- tag_name : ${{github.ref}}
66
- draft : true
67
- prerelease : false
68
- release_name : " Release ${{github.ref}}"
69
- - name : extract tag name
70
- uses : frabert/replace-string-action@v1
71
- with :
72
- pattern : " refs/tags/"
73
- string : ${{github.ref}}
74
- replace-with : " "
75
- id : extract_tag_name
76
- - name : publish nupkg as github release assets
77
-
78
- env :
79
- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
80
- with :
81
- upload_url : ${{steps.create_release.outputs.upload_url}}
82
- asset_path : nupkg/dotnet-compressor.${{ steps.extract_tag_name.outputs.replaced }}.nupkg
83
- asset_name : dotnet-compressor.${{ steps.extract_tag_name.outputs.replaced }}.nupkg
84
- asset_content_type : application/zip
85
- - name : publish snupkg as github release assets
86
-
87
- env :
88
- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
89
- with :
90
- upload_url : ${{steps.create_release.outputs.upload_url}}
91
- asset_path : nupkg/dotnet-compressor.${{ steps.extract_tag_name.outputs.replaced }}.snupkg
92
- asset_name : dotnet-compressor.${{ steps.extract_tag_name.outputs.replaced }}.snupkg
93
- asset_content_type : application/zip
94
- - name : publish macos binary as github release assets
95
-
96
- env :
97
- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
98
- with :
99
- upload_url : ${{steps.create_release.outputs.upload_url}}
100
- asset_path : osx-x64/dcomp
101
- asset_name : dcomp-osx-x64
102
- asset_content_type : application/octet-binary
103
- - name : publish linux binary as github release assets
104
-
105
- env :
106
- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
107
- with :
108
- upload_url : ${{steps.create_release.outputs.upload_url}}
109
- asset_path : linux-x64/dcomp
110
- asset_name : dcomp-linux-x64
111
- asset_content_type : application/octet-binary
112
- - name : publish windows binary as github release assets
113
-
114
- env :
115
- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
116
- with :
117
- upload_url : ${{steps.create_release.outputs.upload_url}}
118
- asset_path : win-x64/dcomp.exe
119
- asset_name : dcomp-win-x64.exe
120
- asset_content_type : application/octet-binary
121
- - name : publish windows binary pdb as github release assets
122
-
123
- env :
124
- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
125
- with :
126
- upload_url : ${{steps.create_release.outputs.upload_url}}
127
- asset_path : win-x64/dcomp.pdb
128
- asset_name : dcomp-win-x64.pdb
129
- asset_content_type : application/octet-binary
130
- - name : upload nupkg to nugetorg
131
- run : " dotnet nuget push -k \" ${{secrets.NUGET_API_KEY}}\" -s https://api.nuget.org/v3/index.json nupkg/dotnet-compressor.${{ steps.extract_tag_name.outputs.replaced }}.nupkg"
0 commit comments