Skip to content

Commit 3a4798e

Browse files
authored
Merge branch 'main' into fix-clippy
2 parents d7c7081 + 7d8d0cf commit 3a4798e

File tree

1 file changed

+26
-11
lines changed

1 file changed

+26
-11
lines changed

.github/workflows/rust.yml

Lines changed: 26 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,9 @@ jobs:
5454
args: --workspace --exclude jpki-android --verbose
5555

5656
build:
57+
needs:
58+
- checks
59+
5760
strategy:
5861
matrix:
5962
target:
@@ -65,14 +68,17 @@ jobs:
6568
include:
6669
- target: x86_64-pc-windows-msvc
6770
host: windows-2022
71+
artifact: jpki-cli.exe
6872
cli: true
6973
android: false
7074
- target: x86_64-apple-darwin
7175
host: macos-12
76+
artifact: jpki-cli
7277
cli: true
7378
android: false
7479
- target: x86_64-unknown-linux-gnu
7580
host: ubuntu-22.04
81+
artifact: jpki-cli
7682
cli: true
7783
android: false
7884
- target: aarch64-linux-android
@@ -119,6 +125,19 @@ jobs:
119125
ln -s "$TOOLCHAIN/llvm-ar" "$TOOLCHAIN/${{ matrix.target }}-ar"
120126
ln -s "$TOOLCHAIN/llvm-ar" "$TOOLCHAIN/arm-linux-androideabi-ar"
121127
128+
- name: Install cargo-edit-version
129+
if: ${{ github.event_name == 'release' }}
130+
uses: actions-rs/cargo@v1
131+
with:
132+
command: install
133+
args: --verbose cargo-edit-version
134+
135+
- name: Set version by the release tag
136+
if: ${{ github.event_name == 'release' }}
137+
run:
138+
cargo-edit-version "${{ github.event.release.tag_name }}"
139+
cd ./cli && cargo-edit-version "${{ github.event.release.tag_name }}"
140+
122141
- name: Build (CLI)
123142
if: ${{ matrix.cli }}
124143
uses: actions-rs/cargo@v1
@@ -134,6 +153,13 @@ jobs:
134153
args: --verbose --release --target=${{ matrix.target }} -p jpki-android
135154
use-cross: true
136155

156+
- uses: svenstaro/upload-release-action@v2
157+
if: ${{ github.event_name == 'release' && matrix.cli }}
158+
with:
159+
file: target/release/${{ matrix.artifact }}
160+
asset_name: jpki-cli-${{ matrix.target }}
161+
overwrite: true
162+
137163
- uses: actions/upload-artifact@v2
138164
if: ${{ matrix.target == 'x86_64-unknown-linux-gnu' }}
139165
with:
@@ -167,17 +193,6 @@ jobs:
167193
- name: Install libpcsclite
168194
run: sudo apt update && sudo apt install libudev-dev libpcsclite-dev
169195

170-
- name: Install cargo-edit-version
171-
uses: actions-rs/cargo@v1
172-
with:
173-
command: install
174-
args: --verbose cargo-edit-version
175-
176-
- name: Set version by the release tag
177-
run:
178-
cargo-edit-version "${{ github.event.release.tag_name }}"
179-
cd ./cli && cargo-edit-version "${{ github.event.release.tag_name }}"
180-
181196
- name: Log into crates.io
182197
uses: actions-rs/cargo@v1
183198
with:

0 commit comments

Comments
 (0)