@@ -28,16 +28,32 @@ jobs:
28
28
- name : Package as zip
29
29
run : |
30
30
md release_package
31
- copy bin\release\* release_package
32
- compress-archive -Path release_package -DestinationPath rmdup_${{github.ref_name }}.zip
31
+ copy .\ bin\Release\net8.0\* .\ release_package
32
+ compress-archive -Path .\ release_package\*.* -DestinationPath rmdup_${{github.sha }}.zip
33
33
- name : Upload artifact
34
34
uses : actions/upload-artifact@v4
35
35
with :
36
- name : rmdup_${{github.ref_name}}.zip
37
- path : rmdup_${{github.ref_name}}.zip
38
-
39
- - name : Release
40
- uses : softprops/action-gh-release@v2
41
- if : startsWith(github.ref, 'refs/tags/')
36
+ name : rmdup_${{github.sha}}.zip
37
+ path : rmdup_${{github.sha}}.zip
38
+
39
+ - name : release to github
40
+ id : create_release
41
+ if : startsWith(github.ref,'refs/tags/')
42
+ uses : actions/create-release@v1
43
+ env :
44
+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
45
+ with :
46
+ tag_name : ${{ github.sha }}
47
+ release_name : ${{ github.sha }}
48
+ draft : true
49
+ prerelease : false
50
+
51
+ - name : publish to github
52
+ uses : actions/upload-release-asset@v1
53
+ env :
54
+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
42
55
with :
43
- files : rmdup_${{github.ref_name}}.zip
56
+ upload_url : ${{ steps.create_release.outputs.upload_url }}
57
+ asset_path : rmdup_${{github.sha}}.zip
58
+ asset_name : rmdup_${{github.sha}}.zip
59
+ asset_content_type : application/zip
0 commit comments