Skip to content

Commit 52b6b52

Browse files
authored
Update wasmtime version in CI (#682)
* Update `wasmtime` version in CI This commit updates the wasmtime version used in CI, which is currently a very outdated version. The new version matches the version used in the CLI. Additionally, this commit introduces a mechanism to retrieve the CLI from `cargo metadata` through `jq` * Use `--format-version=1` and `--locked`
1 parent 05fce92 commit 52b6b52

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

.github/actions/ci-shared-setup/action.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,17 @@ runs:
2525
${{ runner.os }}-cargo-target-${{ hashFiles('Cargo.toml') }}
2626
${{ runner.os }}-cargo-target
2727
28+
- name: Read wasmtime version
29+
id: wasmtime_version
30+
shell: bash
31+
run: |
32+
VERSION=$(cargo metadata --format-version=1 --locked | jq '.packages[] | select(.name == "wasmtime") | .version' -r)
33+
echo "::set-output name=wasmtime_version::$VERSION"
34+
2835
- name: Install wasmtime-cli
29-
env:
30-
WASMTIME_VERSION: 8.0.0
3136
shell: bash
3237
run: |
33-
wget -nv 'https://github.com/bytecodealliance/wasmtime/releases/download/v${{ env.WASMTIME_VERSION }}/wasmtime-v${{ env.WASMTIME_VERSION }}-x86_64-${{ inputs.os }}.tar.xz' -O /tmp/wasmtime.tar.xz
38+
wget -nv 'https://github.com/bytecodealliance/wasmtime/releases/download/v${{ steps.wasmtime_version.outputs.wasmtime_version }}/wasmtime-v${{ steps.wasmtime_version.outputs.wasmtime_version }}-x86_64-${{ inputs.os }}.tar.xz' -O /tmp/wasmtime.tar.xz
3439
mkdir /tmp/wasmtime
3540
tar xvf /tmp/wasmtime.tar.xz --strip-components=1 -C /tmp/wasmtime
3641
echo "/tmp/wasmtime" >> $GITHUB_PATH

0 commit comments

Comments
 (0)