printable-shell-command 0.2.0 → 0.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +6 -4
  2. package/src/index.ts +6 -4
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "printable-shell-command",
3
- "version": "0.2.0",
3
+ "version": "0.2.1",
4
4
  "main": "./src/index.ts",
5
5
  "type": "module",
6
6
  "exports": {
@@ -9,11 +9,13 @@
9
9
  "import": "./src/index.ts"
10
10
  }
11
11
  },
12
- "dependencies": {
12
+ "devDependencies": {
13
+ "@biomejs/biome": "^1.9.4",
13
14
  "@types/bun": "^1.2.11",
14
15
  "@types/node": "^22.15.3"
15
16
  },
16
- "devDependencies": {
17
- "@biomejs/biome": "^1.9.4"
17
+ "optionalDependencies": {
18
+ "@types/bun": "^1.2.11",
19
+ "@types/node": "^22.15.3"
18
20
  }
19
21
  }
package/src/index.ts CHANGED
@@ -1,10 +1,10 @@
1
1
  import type {
2
2
  ChildProcess as NodeChildProcess,
3
+ SpawnOptions as NodeSpawnOptions,
3
4
  SpawnOptionsWithStdioTuple as NodeSpawnOptionsWithStdioTuple,
5
+ SpawnOptionsWithoutStdio as NodeSpawnOptionsWithoutStdio,
4
6
  StdioNull as NodeStdioNull,
5
7
  StdioPipe as NodeStdioPipe,
6
- SpawnOptions as NodeSpawnOptions,
7
- SpawnOptionsWithoutStdio as NodeSpawnOptionsWithoutStdio,
8
8
  } from "node:child_process";
9
9
  import type {
10
10
  SpawnOptions as BunSpawnOptions,
@@ -282,8 +282,10 @@ export class PrintableShellCommand {
282
282
  Stdout extends NodeStdioNull | NodeStdioPipe,
283
283
  Stderr extends NodeStdioNull | NodeStdioPipe,
284
284
  >(
285
- options: NodeSpawnOptions
286
- | NodeSpawnOptionsWithoutStdio | NodeSpawnOptionsWithStdioTuple<Stdin, Stdout, Stderr>,
285
+ options:
286
+ | NodeSpawnOptions
287
+ | NodeSpawnOptionsWithoutStdio
288
+ | NodeSpawnOptionsWithStdioTuple<Stdin, Stdout, Stderr>,
287
289
  ): // TODO: figure out how to return `ChildProcessByStdio<…>` without duplicating fragile boilerplate.
288
290
  NodeChildProcess {
289
291
  const { spawn } = process.getBuiltinModule("node:child_process");