Skip to main content
Module

x/denoexec/mod.ts>ProcessOptions

A higher level wrapper around https://doc.deno.land/builtin/stable#Deno.run
Latest
interface ProcessOptions
import { type ProcessOptions } from "https://deno.land/x/denoexec@v1.1.5/mod.ts";

Properties

cmd: string[]

The first element is the process to execute followed by it's arguments.

optional
cwd: string

Set a custom current working directory for the child process.

optional
env: Record<string, string>

Set a custom environment for the child process.

optional
stdin: string | Uint8Array | Deno.Reader

Send data to the child process via the STDIN stream.

optional
stdout: Deno.Writer

Provide an alternative Writer for the STDOUT stream.

optional
stderr: Deno.Writer

Provide an alternative Writer for the STDERR stream.

optional
prefix: string

If inheritStdio=true & a value is provided here, each line of output will be prefixed with this value.

optional
prefixSeparator: string

If prefix is set then this will be suffixed on to the prefix. Defaults to |.

optional
captureStdio: boolean

If set to true, the default; then output from STDOUT & STDERR will be captured into buffers for later use.

optional
inheritStdio: boolean

If set to true, the default; then output from STDOUT & STDERR will be copied on to the Writers set by stdout & stderr.

optional
throwOnNonZeroExit: boolean

If set to true then a NonZeroExitCode error will be thrown when the process exists with a non-zero exit code.

optional
throwOnStdErr: boolean

If set to true then a NonEmptyStderrBuffer error will be thrown when the stderr buffer contains data.