-
Notifications
You must be signed in to change notification settings - Fork 3
53 lines (43 loc) · 1.04 KB
/
ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
name: Publish release
# on:
# push:
# tags:
# - v*
permissions:
contents: write
jobs:
build-ubuntu:
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install Rust toolchain
run: rustup update
- name: Build
run: cargo build --release
- name: Archive artifact
uses: actions/upload-artifact@v4
with:
name: neophyte-linux
path: target/release/neophyte
retention-days: 1
create-release:
runs-on: ubuntu-latest
timeout-minutes: 5
needs:
- build-ubuntu
steps:
- name: Download Linux artifact
uses: actions/download-artifact@v4
with:
name: neophyte-linux
- name: Create release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
TAG: ${{ github.ref_name }}
run: |
gh release create "$TAG" \
--repo="$GITHUB_REPOSITORY" \
--title="${TAG#v}" \
--notes-from-tag