An open API service indexing awesome lists of open source software.

https://github.com/maxdeviant/wasmtime-current-dir-repro


https://github.com/maxdeviant/wasmtime-current-dir-repro

Last synced: 10 months ago
JSON representation

Awesome Lists containing this project

README

          

# Wasm `std::env::current_dir` repro

```
cargo build --target wasm32-wasip1
wasmtime run --dir=$PWD --env PWD ./target/wasm32-wasip1/debug/wasm-current-dir-repro.wasm
```

## Output

### macOS

```
PWD: "/Users/runner/work/wasmtime-current-dir-repro/wasmtime-current-dir-repro"
Before: "/"
After: "/Users/runner/work/wasmtime-current-dir-repro/wasmtime-current-dir-repro"
```

### Linux

```
PWD: "/home/runner/work/wasmtime-current-dir-repro/wasmtime-current-dir-repro"
Before: "/"
After: "/home/runner/work/wasmtime-current-dir-repro/wasmtime-current-dir-repro"
```

### Windows

```
PWD: "D:/a/wasmtime-current-dir-repro/wasmtime-current-dir-repro"
Before: "/"
After: "/D:/a/wasmtime-current-dir-repro/wasmtime-current-dir-repro"
```