From bdc455dd25b4c0d14fd30bc32c07206b2b93a007 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bartek=20Iwa=C5=84czuk?= Date: Thu, 28 Mar 2019 21:09:46 +0100 Subject: Add Process.stderrOutput() (#1828) --- website/manual.md | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'website') diff --git a/website/manual.md b/website/manual.md index f665d192d..738d84185 100644 --- a/website/manual.md +++ b/website/manual.md @@ -398,8 +398,13 @@ async function main() { const { code } = await p.status(); - const rawOutput = await p.output(); - Deno.stdout.write(rawOutput); + if (code === 0) { + const rawOutput = await p.output(); + Deno.stdout.write(rawOutput); + } else { + const rawError = await p.stderrOutput(); + Deno.stdout.write(rawError); + } Deno.exit(code); } -- cgit v1.2.3