-
Notifications
You must be signed in to change notification settings - Fork 79
49 lines (45 loc) · 1.27 KB
/
Copy pathcheck-package.yml
File metadata and controls
49 lines (45 loc) · 1.27 KB
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
48
49
name: check-package
# This workflow checks if the libraries can be built into distributable, compressed .crate files.
permissions:
contents: read
on:
push:
branches: [main, v*]
pull_request:
branches: [main, v*]
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
env:
CARGO_TERM_COLOR: always
CARGO_INCREMENTAL: 0
RUST_BACKTRACE: 1
jobs:
check-package:
name: Check package
runs-on: ubuntu-latest
timeout-minutes: 20
strategy:
fail-fast: false
matrix:
package:
- openzeppelin-crypto
- openzeppelin-stylus-proc
- openzeppelin-stylus
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install Rust toolchain
uses: actions-rust-lang/setup-rust-toolchain@v1
with:
rustflags: ""
cache: true
target: wasm32-unknown-unknown
- name: Check package ${{ matrix.package }}
run: cargo package -p ${{ matrix.package }} --target wasm32-unknown-unknown
- name: Verify package contents
run: |
crate_file=$(find target/package -name "${{ matrix.package }}-*.crate" | head -1)
if [ -z "$crate_file" ]; then
exit 1
fi