diff --git a/docs/lang-bash.md b/docs/lang-bash.md index fba5f9a741f3..bc1f8f829493 100644 --- a/docs/lang-bash.md +++ b/docs/lang-bash.md @@ -30,7 +30,7 @@ function gcd() { local x=$(($1)) local y=$(($2)) # Invoke GCD from module; suppress stderr - local result=$(wasmtime examples/gcd.wat --invoke gcd $x $y 2>/dev/null) + local result=$(wasmtime --invoke gcd examples/gcd.wat $x $y 2>/dev/null) echo "$result" } diff --git a/src/bin/wasmtime.rs b/src/bin/wasmtime.rs index 3ca25c7dfca1..a8e90550552f 100644 --- a/src/bin/wasmtime.rs +++ b/src/bin/wasmtime.rs @@ -24,7 +24,7 @@ use clap::Parser; \n\ Invoking a specific function (e.g. `add`) in a WebAssembly module:\n\ \n \ - wasmtime example.wasm --invoke add 1 2\n", + wasmtime --invoke add example.wasm 1 2\n", // This option enables the pattern below where we ask clap to parse twice // sorta: once where it's trying to find a subcommand and once assuming