Skip to content

Commit 8a1bbf4

Browse files
committed
Add self-hosted build asset deployment to GitHub releases in the CI action
1 parent 78337f9 commit 8a1bbf4

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

.github/workflows/production-build.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
build:
1313
runs-on: self-hosted
1414
permissions:
15-
contents: read
15+
contents: write
1616
deployments: write
1717
env:
1818
RUSTC_WRAPPER: /usr/bin/sccache
@@ -66,3 +66,13 @@ jobs:
6666
projectName: graphite-editor
6767
directory: frontend/dist
6868
branch: master
69+
70+
- name: 📦 Upload assets to GitHub release
71+
env:
72+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
73+
run: |
74+
DATE=$(date +%F)
75+
cd frontend
76+
mv dist "graphite-$DATE"
77+
zip -r "graphite-self-hosted-build.zip" "graphite-$DATE"
78+
gh release upload ${{ github.event.release.tag_name }} "graphite-self-hosted-build.zip" --clobber

0 commit comments

Comments
 (0)