File tree Expand file tree Collapse file tree 1 file changed +31
-0
lines changed
Expand file tree Collapse file tree 1 file changed +31
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Generate assets on releases
2+
3+ on :
4+ release :
5+ types :
6+ - released
7+
8+ jobs :
9+ assets :
10+ runs-on : ubuntu-latest
11+ steps :
12+ - name : Checkout code
13+ uses : actions/checkout@v4
14+ with :
15+ submodules : true
16+
17+ - name : Generate archives
18+ env :
19+ GH_TOKEN : ${{ github.token }}
20+ run : |
21+ tag="${GITHUB_REF#refs/tags/}"
22+ git archive --prefix="ocaml-$tag/" @ >ocaml.tar
23+ git -C winpthreads archive --prefix="ocaml-$tag/winpthreads/" @ >w.tar
24+ cp ocaml.tar ocaml-winpthreads.tar
25+ tar -A -f ocaml-winpthreads.tar w.tar
26+ xz ocaml.tar
27+ osha="$(sha256sum ocaml.tar.xz | awk '{print $1}')"
28+ xz ocaml-winpthreads.tar
29+ owsha="$(sha256sum ocaml-winpthreads.tar.xz | awk '{print $1}')"
30+ gh release upload "$tag" "ocaml.tar.xz#ocaml.tar.xz ($osha)"
31+ gh release upload "$tag" "ocaml-winpthreads.tar.xz#ocaml-winpthreads.tar.xz ($owsha)"
You can’t perform that action at this time.
0 commit comments