Skip to content

Commit

Permalink
fix: handle nullable stdout/stderr (#943)
Browse files Browse the repository at this point in the history
closes #942
  • Loading branch information
antongolub authored Nov 10, 2024
1 parent 7711a5c commit 3b6c120
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 16 deletions.
22 changes: 11 additions & 11 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "zx",
"version": "8.2.1",
"version": "8.2.2",
"description": "A tool for writing better scripts",
"type": "module",
"main": "./build/index.cjs",
Expand Down Expand Up @@ -80,7 +80,7 @@
"test:smoke:tsx": "tsx test/smoke/ts.test.ts",
"test:smoke:tsc": "cd test/smoke && mkdir -p node_modules && ln -s ../../../ ./node_modules/zx; ../../node_modules/typescript/bin/tsc -v && ../../node_modules/typescript/bin/tsc --esModuleInterop --module node16 --rootDir . --outdir ./temp ts.test.ts && node ./temp/ts.test.js",
"test:smoke:ts-node": "node --loader ts-node/esm test/smoke/ts.test.ts",
"test:smoke:bun": "bun test ./test/smoke/bun.test.js",
"test:smoke:bun": "bun test ./test/smoke/bun.test.js && bun ./test/smoke/node.test.mjs",
"test:smoke:win32": "node ./test/smoke/win32.test.js",
"test:smoke:cjs": "node ./test/smoke/node.test.cjs",
"test:smoke:mjs": "node ./test/smoke/node.test.mjs",
Expand All @@ -97,7 +97,7 @@
"@types/node": ">=20.11.30",
"@types/which": "^3.0.4",
"@webpod/ingrid": "^0.0.0-beta.3",
"@webpod/ps": "^0.0.0-beta.10",
"@webpod/ps": "^0.0.0-beta.11",
"c8": "^10.1.2",
"chalk": "^5.3.0",
"create-require": "^1.1.1",
Expand All @@ -124,7 +124,7 @@
"typescript": "^5.6.3",
"which": "^5.0.0",
"yaml": "^2.5.1",
"zurk": "^0.6.0"
"zurk": "^0.6.2"
},
"publishConfig": {
"registry": "https://wombat-dressing-room.appspot.com"
Expand Down
4 changes: 3 additions & 1 deletion test/core.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,9 @@ describe('core', () => {
})

test('inherit', async () => {
await $({ stdio: 'inherit' })`ls`
const r1 = (await $({ stdio: 'inherit' })`ls`).stdout
const r2 = $.sync({ stdio: 'inherit' })`ls`.stdout
assert.equal(r1, r2)
})

test('file stream as stdout', async () => {
Expand Down

0 comments on commit 3b6c120

Please sign in to comment.