@@ -2,8 +2,10 @@ name: Build and Publish Binaries
22run-name : Release binaries for ${{ github.ref_name }} by @${{ github.actor }}
33
44on :
5- release :
6- types : [created]
5+ workflow_dispatch :
6+ push :
7+ paths :
8+ - " wally.toml"
79
810permissions :
911 contents : write
@@ -13,23 +15,91 @@ concurrency:
1315 cancel-in-progress : true
1416
1517jobs :
18+ manifest :
19+ runs-on : ubuntu-latest
20+
21+ outputs :
22+ version : ${{ fromJSON(steps.set_manifest.outputs.manifest).package.version }}
23+
24+ steps :
25+ - name : Checkout repository
26+ uses : actions/checkout@v6
27+
28+ - name : Setup Rokit
29+ uses : CompeyDev/setup-rokit@v0.2.1
30+ with :
31+ cache : true
32+
33+ - name : Set Manifest
34+ id : set_manifest
35+ run : echo "manifest=$(wally manifest-to-json)" >> $GITHUB_OUTPUT
36+
1637 build :
1738 runs-on : ubuntu-latest
1839
1940 steps :
20- - name : Checkout
41+ - name : Checkout repository
2142 uses : actions/checkout@v6
2243
2344 # Build steps
2445 - name : Setup Rokit
25- uses : CompeyDev/setup-rokit@v0.1.2
46+ uses : CompeyDev/setup-rokit@v0.2.1
2647 with :
2748 cache : true
2849 - name : Build
2950 run : rojo build -o Overture.rbxm
3051
3152 # Upload steps
32- - name : Release
33- uses : softprops/action-gh-release@v2
53+ - name : Upload build
54+ uses : actions/upload-artifact@v7
3455 with :
35- files : Overture.rbxm
56+ path : " *.rbxm"
57+ if-no-files-found : error
58+
59+ publish-github :
60+ if : github.ref == 'refs/heads/main' || (contains(needs.manifest.outputs.version, '-') && github.event_name == 'workflow_dispatch')
61+
62+ needs : [build, manifest]
63+ runs-on : ubuntu-latest
64+
65+ permissions :
66+ contents : write
67+
68+ steps :
69+ - name : Download
70+ uses : actions/download-artifact@v8
71+
72+ - uses : ncipollo/release-action@v1
73+ with :
74+ name : ${{ needs.manifest.outputs.version }}
75+ tag : v${{ needs.manifest.outputs.version }}
76+ commit : ${{ github.head_ref || github.ref_name }}
77+ artifacts : " **/*.rbxm"
78+ prerelease : ${{ contains(needs.manifest.outputs.version, '-') }}
79+ generateReleaseNotes : true
80+ immutableCreate : true
81+
82+ publish-wally :
83+ needs : [build, publish-github]
84+ runs-on : ubuntu-latest
85+
86+ steps :
87+ - name : Checkout repository
88+ uses : actions/checkout@v6
89+
90+ - name : Setup Rokit
91+ uses : CompeyDev/setup-rokit@v0.1.2
92+ with :
93+ cache : true
94+
95+ - name : Log in to wally
96+ env :
97+ WALLY_AUTH : |
98+ [tokens]
99+ "https://api.wally.run/" = "${{ secrets.WALLY_AUTH }}"
100+ run : |
101+ mkdir ~/.wally
102+ printenv WALLY_AUTH > ~/.wally/auth.toml
103+
104+ - name : Push update to wally
105+ run : wally publish
0 commit comments