Skip to content

Commit

Permalink
Fix WASI target name
Browse files Browse the repository at this point in the history
  • Loading branch information
djc committed Feb 26, 2025
1 parent f37cb6e commit 03965f9
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .cargo/config.toml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
[target.wasm32-wasi]
[target.wasm32-wasip1]
runner = ["./scripts/wasmtime-wrapper.sh"]
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ jobs:
strategy:
fail-fast: false
matrix:
target: [wasm32-wasi]
target: [wasm32-wasip1]
runs-on: ubuntu-latest
steps:
- name: Install rust
Expand Down
4 changes: 2 additions & 2 deletions src/wasm_term.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@ pub const DEFAULT_WIDTH: u16 = 80;

#[inline]
pub fn is_a_terminal(_out: &Term) -> bool {
#[cfg(target = "wasm32-wasi")]
#[cfg(target = "wasm32-wasip1")]
{
unsafe { libc::isatty(out.as_raw_fd()) != 0 }
}
#[cfg(not(target = "wasm32-wasi"))]
#[cfg(not(target = "wasm32-wasip1"))]
{
false
}
Expand Down

0 comments on commit 03965f9

Please sign in to comment.