Skip to content

Commit d77c66d

Browse files
authored
fix: binary check actually work (#1075)
Signed-off-by: Andrew Tretyakov <[email protected]>
1 parent 025c012 commit d77c66d

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

.github/workflows/rust.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,14 @@ jobs:
9494
- name: Use the `jolt` binary to generate code
9595
run: ./target/release/jolt new sample_project
9696

97+
- name: Pin jolt-sdk to current commit in Cargo.toml files
98+
run: |
99+
COMMIT_HASH=$(git rev-parse HEAD)
100+
# Pin jolt-sdk in the host Cargo.toml
101+
sed -i 's|jolt-sdk = { git = "https://github.com/a16z/jolt", features = \["host"\] }|jolt-sdk = { git = "https://github.com/a16z/jolt", rev = "'$COMMIT_HASH'", features = ["host"] }|' sample_project/Cargo.toml
102+
# Pin jolt-sdk in the guest Cargo.toml
103+
sed -i 's|jolt = { package = "jolt-sdk", git = "https://github.com/a16z/jolt" }|jolt = { package = "jolt-sdk", git = "https://github.com/a16z/jolt", rev = "'$COMMIT_HASH'" }|' sample_project/guest/Cargo.toml
104+
97105
- name: Make sure the generated code runs
98106
working-directory: ./sample_project
99107
run: cargo run --release

0 commit comments

Comments
 (0)