Skip to content

Commit b07674c

Browse files
committed
Add release action
1 parent ec81f8c commit b07674c

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed

.github/workflows/release.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Release
2+
on:
3+
# schedule:
4+
# - cron: '0 0 1 * *' # midnight UTC every month
5+
6+
push:
7+
tags:
8+
- 'v[0-9]+.[0-9]+.[0-9]+'
9+
10+
jobs:
11+
release:
12+
name: Release binaries
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v2
16+
17+
- uses: actions-rs/toolchain@v1
18+
with:
19+
profile: minimal
20+
toolchain: stable
21+
22+
- name: Build release binary
23+
run: cargo build --release --locked --verbose
24+
25+
- name: Strip release binary
26+
run: strip target/release/dosnap
27+
28+
- name: Upload binaries to release
29+
uses: svenstaro/upload-release-action@v2
30+
with:
31+
repo_token: ${{ secrets.GITHUB_TOKEN }}
32+
file: target/release/dosnap
33+
asset_name: dosnap
34+
tag: ${{ github.ref }}
35+
overwrite: true

0 commit comments

Comments
 (0)