-
Notifications
You must be signed in to change notification settings - Fork 0
47 lines (42 loc) · 1.2 KB
/
release.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
name: Release
on:
push:
tags:
- '*'
env:
CARGO_TERM_COLOR: always
jobs:
build:
env:
FILE_NAME: flora_parsing
runs-on: ${{ matrix.os }}
permissions: write-all
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest,macOS-latest,windows-latest]
steps:
- uses: actions/checkout@v4
- name: Run tests
run: cargo test --verbose
- name: release
run: cargo build --release
- name: 'Tar files'
run: tar -cvf ${{ matrix.os }}-${{ env.FILE_NAME }}.tar ./target/release
- name: upload artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.os }}-${{ env.FILE_NAME }}
path: ${{ matrix.os }}-${{ env.FILE_NAME }}.tar
release:
needs: build
runs-on: ubuntu-latest
permissions: write-all
strategy:
fail-fast: false
steps:
- name: Download all workflow run artifacts
uses: actions/download-artifact@v4
- uses: ncipollo/release-action@v1
with:
artifacts: './ubuntu-latest-flora_parsing/ubuntu-latest-flora_parsing.tar,./macOS-latest-flora_parsing.macOS-latest-flora_parsing.tar,./windows-latest-flora_parsing/windows-latest-flora_parsing.tar'