Skip to content

Commit 71253c1

Browse files
authored
refactor(bindings): change bindings generation and prepare to local testing tool (#49)
* add new tools crates and update bindings generation * remove deployer for now * rework bindings and prepare for deployer/local testing tool * add missing newline * add rust-toolchain file with arbitrary version * update ci to use defined rust version * update ci to test dual toolchain * ci wip * ci wip * add missing component rustfmt * rename Appchain to AppchainContract in bindings * chore: bump cainome * add cairo serde * fix cainome revision * add missing Cargo.lock updates
1 parent 13ab512 commit 71253c1

16 files changed

+5799
-4393
lines changed

.github/workflows/build.yml

+9-2
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,23 @@ on:
99
permissions: read-all
1010

1111
jobs:
12-
build_default:
12+
default:
1313
runs-on: ubuntu-latest
1414
steps:
1515
- uses: actions/checkout@v4
1616
- uses: asdf-vm/actions/[email protected]
1717
- run: scarb build
1818

19-
build_all_features:
19+
all_features:
2020
runs-on: ubuntu-latest
2121
steps:
2222
- uses: actions/checkout@v4
2323
- uses: asdf-vm/actions/[email protected]
2424
- run: scarb build --all-features
25+
26+
rust:
27+
runs-on: ubuntu-latest
28+
steps:
29+
- uses: actions/checkout@v4
30+
- uses: dtolnay/rust-toolchain@stable
31+
- run: cargo build -p piltover

.github/workflows/check.yml

+16
Original file line numberDiff line numberDiff line change
@@ -32,3 +32,19 @@ jobs:
3232
- uses: actions/checkout@v4
3333
- uses: asdf-vm/actions/[email protected]
3434
- run: scarb test --all-features
35+
36+
rust_bindings:
37+
runs-on: ubuntu-latest
38+
steps:
39+
- uses: actions/checkout@v4
40+
- uses: dtolnay/rust-toolchain@stable
41+
- uses: dtolnay/rust-toolchain@v1
42+
with:
43+
toolchain: nightly-2024-08-28
44+
components: rustfmt
45+
- uses: asdf-vm/actions/[email protected]
46+
- name: Generate bindings
47+
run: bash scripts/generate_bindings.sh
48+
- name: Check for changes
49+
run: |
50+
git diff --exit-code || (echo "Error: Generated bindings are not up to date. Please run 'bash scripts/generate_bindings.sh' and commit the changes." && exit 1)

0 commit comments

Comments
 (0)