tauri-apps / tauri-apps/plugins-workspace
shell: stdin write does not work with `bun`
Open
plugin: shell
status: upstream
type: bug
- Dominant language
- Rust
- Stars
- 1.8k
- Forks
- 602
- Avg merge
- 4d 14h
- Merged PRs (30d)
- 9
Description
- os: mac 15
- bun: 1.2.8
- tauri: latest
The app code:
```ts
const cmd = Command.create("bun", ["foo.ts"], {
encoding: "utf8",
});
cmd.stdout.on("data", (data) => {
console.log("stdout", data);
});
const child = await cmd.spawn();
await child.write("hello bun\n");
```
The bun script:
```ts
process.stdin.on("data", (data) => {
console.log("you typed:", data.toString());
});
```
The data event on stdin is never emitted, most likely a bun bug but I'm posting here just in case.
Here is the repro: https://github.com/egoist-bot/bun-stdin-bug
Contributor guide
Assessment
This issue has not been assessed yet.