-
-
Notifications
You must be signed in to change notification settings - Fork 53
44 lines (38 loc) · 1.22 KB
/
publish.yaml
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
name: Publish executables
on:
workflow_dispatch:
push:
tags:
- 'v*'
jobs:
publish:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ macos-latest, ubuntu-latest, windows-latest ]
include:
- os: windows-latest
executable_name: examples/keyring-cli.exe
posted_name: keyring-cli.windows.exe
- os: macos-latest
executable_name: examples/keyring-cli
posted_name: keyring-cli.macos
- os: ubuntu-latest
executable_name: examples/keyring-cli
posted_name: keyring-cli.linux
steps:
- name: Fetch head
uses: actions/checkout@v4
- name: Install rust stable
uses: actions-rust-lang/setup-rust-toolchain@v1
with:
toolchain: stable
- name: Build
run: cargo build --release --features=apple-native,windows-native,linux-native --example keyring-cli
- name: Post keyring-cli executable
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: target/release/${{ matrix.executable_name }}
asset_name: ${{ matrix.posted_name }}
tag: ${{ github.ref }}