File tree Expand file tree Collapse file tree 2 files changed +56
-0
lines changed Expand file tree Collapse file tree 2 files changed +56
-0
lines changed Original file line number Diff line number Diff line change 1+ * @ software-artificer
Original file line number Diff line number Diff line change 1+ name : Release
2+
3+ on :
4+ push :
5+ tags :
6+ - ' v*'
7+
8+ jobs :
9+ build-linux :
10+ runs-on : ubuntu-latest
11+ steps :
12+ - uses : actions/checkout@v5
13+ - uses : actions-rust-lang/setup-rust-toolchain@v1
14+ with :
15+ toolchain : stable
16+ - name : Run the release build
17+ run : cargo build --release --target=x86_64-unknown-linux-gnu
18+ env :
19+ RUSTFLAGS : -C target-feature=+crt-static
20+ - name : Copy the resulting binary into the project root
21+ run : cp -v target/x86_64-unknown-linux-gnu/release/mctrlrs mctrlrs
22+ - name : Create the release archive
23+ run : |
24+ tar -cvjf "mctrlrs-${{ github.ref_name }}-x86_64-linux.tar.bz2" \
25+ mctrlrs static/ templates/ config.yml
26+ env :
27+ BZIP : --best
28+ - uses : actions/upload-artifact@v4
29+ with :
30+ name : x86_64-linux
31+ path : " target/x86_64-unknown-linux-gnu/release/mctrlrs-${{ github.ref_name }}-x86_64-linux.tar.bz2"
32+ if-no-files-found : error
33+ retention-days : 1
34+ compression-level : 0
35+
36+ release :
37+ runs-on : ubuntu-latest
38+ permissions :
39+ contents : write
40+ needs :
41+ - build-linux
42+ - build-macos
43+ steps :
44+ - uses : actions/download-artifact@v5
45+ with :
46+ name : x86_64-linux
47+ - name : Create a GitHub release
48+ run : |
49+ gh release create ${{ github.ref_name }} --draft --generate-notes \
50+ --prerelease --title "Release ${{ github.ref_name }} draft" \
51+ --repo "${{ github.repository }}" \
52+ "mctrlrs-${{ github.ref_name }}-x86_64-linux.tar.bz2"
53+ env :
54+ GH_TOKEN : ${{ github.token }}
55+
You can’t perform that action at this time.
0 commit comments