diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 94edff7..189d746 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -21,8 +21,16 @@ jobs:
run: |
./install-wasi-sdk.sh
go install github.com/extism/cli/extism@latest
+ cd /tmp
+ # get just wasm-merge and wasm-opt
+ curl -L https://github.com/WebAssembly/binaryen/releases/download/version_116/binaryen-version_116-x86_64-linux.tar.gz > binaryen.tar.gz
+ tar xvzf binaryen.tar.gz
+ sudo cp binaryen-version_116/bin/wasm-merge /usr/local/bin
+ sudo cp binaryen-version_116/bin/wasm-opt /usr/local/bin
- name: Test
+ env:
+ QUICKJS_WASM_SYS_WASI_SDK_PATH: "${{ github.workspace }}/wasi-sdk"
run: |
make
make test
diff --git a/Cargo.toml b/Cargo.toml
index 281434e..fceafcc 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -6,10 +6,10 @@ members = [
]
[workspace.package]
-version = "1.0.0-rc2"
+version = "1.0.0-rc3"
edition = "2021"
authors = ["The Extism Authors"]
license = "BSD-Clause-3"
[workspace.dependencies]
-anyhow = "1.0.68"
+anyhow = "^1.0.68"
diff --git a/Makefile b/Makefile
index 9f339e6..3051d01 100644
--- a/Makefile
+++ b/Makefile
@@ -8,7 +8,7 @@ install:
cargo install --path crates/cli
cli: core
- cd crates/cli && QUICKJS_WASM_SYS_WASI_SDK_PATH="$(CURDIR)/wasi-sdk/" cargo build --release && cd -
+ cd crates/cli && cargo build --release && cd -
core:
cd crates/core \
@@ -16,7 +16,7 @@ core:
&& npm install \
&& npm run build \
&& cd ../.. \
- && QUICKJS_WASM_SYS_WASI_SDK_PATH="$(CURDIR)/wasi-sdk/" cargo build --release --target=wasm32-wasi \
+ && cargo build --release --target=wasm32-wasi \
&& cd -
fmt: fmt-core fmt-cli
@@ -46,5 +46,5 @@ test: compile-examples
@extism call examples/bundled.wasm greet --wasi --input="Benjamin"
compile-examples:
- ./target/release/extism-js examples/simple_js/script.js -o examples/simple_js.wasm
+ ./target/release/extism-js examples/simple_js/script.js -i examples/simple_js/script.d.ts -o examples/simple_js.wasm
cd examples/bundled && npm install && npm run build && cd ../..
diff --git a/README.md b/README.md
index 6dc831c..8348f17 100644
--- a/README.md
+++ b/README.md
@@ -23,15 +23,19 @@ curl -O https://raw.githubusercontent.com/extism/js-pdk/main/install.sh
sh install.sh
```
+> *Note*: [Binaryen](https://github.com/WebAssembly/binaryen), specifcally the wasm-merge tool
+> is required as a dependency. We will try to package this up eventually but for now it must be reachable
+> on your machine. You can install on mac with `brew install binaryen` or see their [releases page](https://github.com/WebAssembly/binaryen/releases).
+
Then run command with no args to see the help:
```
extism-js
error: The following required arguments were not provided:
-
+
USAGE:
- extism-js -o