forked from paritytech/smart-bench
-
Notifications
You must be signed in to change notification settings - Fork 0
78 lines (68 loc) · 2.25 KB
/
ci.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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
name: Build examples
on:
push:
branches:
- master
pull_request:
types: [opened, synchronize, reopened, ready_for_review]
jobs:
build:
name: Cargo Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
- uses: actions-rs/cargo@v1
with:
command: build
args: --release --all-features
quick_check:
strategy:
matrix:
os: ["ubuntu-latest"]
runs-on: ${{ matrix.os }}
steps:
- name: Install Rust toolchain
uses: actions-rs/toolchain@b2417cde72dcf67f306c0ae8e0828a81bf0b189f # v1.0.7
with:
profile: minimal
toolchain: stable
override: true
- name: Install Rust nightly toolchain
uses: actions-rs/toolchain@b2417cde72dcf67f306c0ae8e0828a81bf0b189f # v1.0.7
with:
profile: minimal
toolchain: nightly
override: true
components: rust-src
- name: Cache Dependencies & Build Outputs
uses: actions/cache@9b0c1fce7a93df8e3bb8926b0d6e9d89e92f20a7 # v3.0.11
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ runner.os }}-${{ matrix.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- name: Install cargo-dylint
uses: baptiste0928/cargo-install@bf6758885262d0e6f61089a9d8c8790d3ac3368f #v1.3.0
with:
crate: cargo-dylint
- name: Install dylint-link
uses: baptiste0928/cargo-install@bf6758885262d0e6f61089a9d8c8790d3ac3368f #v1.3.0
with:
crate: dylint-link
- name: Install cargo-contract
uses: baptiste0928/cargo-install@bf6758885262d0e6f61089a9d8c8790d3ac3368f #v1.3.0
with:
crate: cargo-contract
version: "2.0.0-rc"
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8 # v3.1.0
- name: Install cargo-contract and build contract
shell: bash
run: |
git clone --verbose --depth 1 https://github.com/paritytech/ink.git
mv Cargo.toml _Cargo.toml
./scripts/ci/build-contract.sh ./ink/integration-tests/public/erc20
mv _Cargo.toml Cargo.toml