-
Notifications
You must be signed in to change notification settings - Fork 0
41 lines (39 loc) · 910 Bytes
/
rust.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
name: Rust-Binary-Build
on:
push:
branches: [ "main" ]
tags:
- v*
- release/*
env:
CARGO_TERM_COLOR: always
jobs:
build:
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
- name: Run tests
run: cargo test --verbose
- name: Build
run: cargo build --verbose --release
- name: Publish artifacts
uses: actions/upload-artifact@master
with:
name: cimutil
path: target/release/*.exe
release:
name: Release
runs-on: ubuntu-latest
needs: [ 'build' ]
if: startsWith(github.ref, 'refs/tags/release')
steps:
- name: Download Artifacts
uses: actions/download-artifact@master
with:
name: cimutil
path: build/
- name: Release
uses: fnkr/github-action-ghr@v1
env:
GHR_PATH: build/
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}