Commit a521e8e 1 parent c1caafc commit a521e8e Copy full SHA for a521e8e
File tree 1 file changed +40
-0
lines changed
1 file changed +40
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Release Creation
2
+
3
+ on :
4
+ release :
5
+ types : [published]
6
+
7
+ jobs :
8
+ build :
9
+ runs-on : ubuntu-latest
10
+ steps :
11
+ - uses : actions/checkout@v2
12
+
13
+ # Substitute the Manifest and Download URLs in the module.json
14
+ - name : Substitute Manifest and Download Links For Versioned Ones
15
+ id : sub_manifest_link_version
16
+ uses : microsoft/variable-substitution@v1
17
+ with :
18
+ files : ' module.json'
19
+ env :
20
+ version : ${{github.event.release.tag_name}}
21
+ url : https://github.com/${{github.repository}}
22
+ manifest : https://github.com/${{github.repository}}/releases/latest/download/module.json
23
+ download : https://github.com/${{github.repository}}/releases/download/${{github.event.release.tag_name}}/module.zip
24
+
25
+ # Create a zip file with all files required by the module to add to the release
26
+ - run : zip -r ./module.zip module.json LICENSE styles/ scripts/ templates/ lang/
27
+
28
+ # Create a release for this specific version
29
+ - name : Update Release with Files
30
+ id : create_version_release
31
+ uses : ncipollo/release-action@v1
32
+ with :
33
+ allowUpdates : true # Set this to false if you want to prevent updating existing releases
34
+ name : ${{ github.event.release.name }}
35
+ draft : false
36
+ prerelease : false
37
+ token : ${{ secrets.GITHUB_TOKEN }}
38
+ artifacts : ' ./module.json, ./module.zip'
39
+ tag : ${{ github.event.release.tag_name }}
40
+ body : ${{ github.event.release.body }}
You can’t perform that action at this time.
0 commit comments