Skip to content

Upgrading execa 5 to 6

Breaking5.1.1 → 6.1.0Breaking2Platform1New2

BreakingUpgrade verdict

2 breaking changes and a platform requirement change.

  • The package can only be loaded using modern JavaScript import syntax, not the older require() function.
  • Instead of one default import, you now import specific named functions from the package.
  • This version needs a newer version of Node.js (12.20 or above) to run.
3 items need code or config changes

Node.js requirement changed in 6.0.0: >=10 → ^12.20.0 || ^14.13.1 || >=16.0.0.

Installs 16 packages in all (was 15).

Breaking2
Package is now pure ESM, so it can no longer be loaded with require().
Replaces the default export with named exports such as execa, execaSync, execaCommand, execaCommandSync and execaNode.
execaexecaSyncexecaCommandexecaCommandSyncexecaNode
Platform1
Requires Node.js 12.20 or later.

Generated by DepDelta from published .d.ts files. Not mixed with prose notes.

  • removed: const execa: { (file: string, arguments?: readonly string[], options?: execa.Options): execa.ExecaChildProcess; (file: string, arguments?: readonly string[], options?: exec…
  • removed: export = execa
  • removed: interface execa.CommonOptions<EncodingType>
  • removed: interface execa.ExecaChildPromise<StdoutErrorType>
  • removed: interface execa.ExecaError<StdoutErrorType = string> extends ExecaSyncError<StdoutErrorType>
  • removed: interface execa.ExecaReturnBase<StdoutStderrType>
  • removed: interface execa.ExecaReturnValue<StdoutErrorType = string> extends ExecaSyncReturnValue<StdoutErrorType>
  • removed: interface execa.ExecaSyncError<StdoutErrorType = string> extends Error, ExecaReturnBase<StdoutErrorType>
  • removed: interface execa.ExecaSyncReturnValue<StdoutErrorType = string> extends ExecaReturnBase<StdoutErrorType>
  • removed: interface execa.KillOptions
  • removed: interface execa.NodeOptions<EncodingType = string> extends Options<EncodingType>
  • removed: interface execa.Options<EncodingType = string> extends CommonOptions<EncodingType>
  • removed: interface execa.SyncOptions<EncodingType = string> extends CommonOptions<EncodingType>
  • removed: method execa.ExecaChildPromise.cancel(): void
  • removed: method execa.ExecaChildPromise.catch<ResultType = never>(onRejected?: (reason: ExecaError<StdoutErrorType>) => ResultType | PromiseLike<ResultType>): Promise<ExecaReturnValue<StdoutErrorType> | ResultType>
  • removed: method execa.ExecaChildPromise.kill(signal?: string, options?: KillOptions): void
  • removed: namespace execa
  • removed: property execa.ExecaChildPromise.all?: ReadableStream
  • removed: property execa.ExecaError.all?: StdoutErrorType
  • removed: property execa.ExecaError.isCanceled: boolean
  • removed: property execa.ExecaReturnBase.command: string
  • removed: property execa.ExecaReturnBase.escapedCommand: string
  • removed: property execa.ExecaReturnBase.exitCode: number
  • removed: property execa.ExecaReturnBase.failed: boolean
  • removed: property execa.ExecaReturnBase.killed: boolean
  • removed: property execa.ExecaReturnBase.signal?: string
  • removed: property execa.ExecaReturnBase.signalDescription?: string
  • removed: property execa.ExecaReturnBase.stderr: StdoutStderrType
  • removed: property execa.ExecaReturnBase.stdout: StdoutStderrType
  • removed: property execa.ExecaReturnBase.timedOut: boolean
  • removed: property execa.ExecaReturnValue.all?: StdoutErrorType
  • removed: property execa.ExecaReturnValue.isCanceled: boolean
  • removed: property execa.ExecaSyncError.message: string
  • removed: property execa.ExecaSyncError.originalMessage?: string
  • removed: property execa.ExecaSyncError.shortMessage: string
  • removed: property execa.KillOptions.forceKillAfterTimeout?: number | false
  • removed: readonly property execa.CommonOptions.all?: boolean
  • removed: readonly property execa.CommonOptions.argv0?: string
  • removed: readonly property execa.CommonOptions.buffer?: boolean
  • removed: readonly property execa.CommonOptions.cleanup?: boolean
  • removed: readonly property execa.CommonOptions.cwd?: string
  • removed: readonly property execa.CommonOptions.detached?: boolean
  • removed: readonly property execa.CommonOptions.encoding?: EncodingType
  • removed: readonly property execa.CommonOptions.env?: NodeJS.ProcessEnv
  • removed: readonly property execa.CommonOptions.execPath?: string
  • removed: readonly property execa.CommonOptions.extendEnv?: boolean
  • removed: readonly property execa.CommonOptions.gid?: number
  • removed: readonly property execa.CommonOptions.killSignal?: string | number
  • removed: readonly property execa.CommonOptions.localDir?: string
  • removed: readonly property execa.CommonOptions.maxBuffer?: number
  • removed: readonly property execa.CommonOptions.preferLocal?: boolean
  • removed: readonly property execa.CommonOptions.reject?: boolean
  • removed: readonly property execa.CommonOptions.serialization?: 'json' | 'advanced'
  • removed: readonly property execa.CommonOptions.shell?: boolean | string
  • removed: readonly property execa.CommonOptions.stderr?: StdioOption
  • removed: readonly property execa.CommonOptions.stdin?: StdioOption
  • removed: readonly property execa.CommonOptions.stdio?: 'pipe' | 'ignore' | 'inherit' | readonly StdioOption[]
  • removed: readonly property execa.CommonOptions.stdout?: StdioOption
  • removed: readonly property execa.CommonOptions.stripFinalNewline?: boolean
  • removed: readonly property execa.CommonOptions.timeout?: number
  • removed: readonly property execa.CommonOptions.uid?: number
  • removed: readonly property execa.CommonOptions.windowsHide?: boolean
  • removed: readonly property execa.CommonOptions.windowsVerbatimArguments?: boolean
  • removed: readonly property execa.NodeOptions.nodeOptions?: string[]
  • removed: readonly property execa.NodeOptions.nodePath?: string
  • removed: readonly property execa.Options.input?: string | Buffer | ReadableStream
  • removed: readonly property execa.SyncOptions.input?: string | Buffer
  • removed: type execa.ExecaChildProcess<StdoutErrorType = string> = ChildProcess & ExecaChildPromise<StdoutErrorType> & Promise<ExecaReturnValue<StdoutErrorType>>
  • removed: type execa.StdioOption = 'pipe' | 'ipc' | 'ignore' | 'inherit' | Stream | number | undefined
  • added: function execa(file: string, arguments?: readonly string[], options?: Options): ExecaChildProcess
  • added: function execa(file: string, arguments?: readonly string[], options?: Options<null>): ExecaChildProcess<Buffer>
  • added: function execa(file: string, options?: Options): ExecaChildProcess
  • added: function execa(file: string, options?: Options<null>): ExecaChildProcess<Buffer>
  • added: function execaCommand(command: string, options?: Options): ExecaChildProcess
  • added: function execaCommand(command: string, options?: Options<null>): ExecaChildProcess<Buffer>
  • added: function execaCommandSync(command: string, options?: SyncOptions): ExecaSyncReturnValue
  • added: function execaCommandSync(command: string, options?: SyncOptions<null>): ExecaSyncReturnValue<Buffer>
  • added: function execaNode(scriptPath: string, arguments?: readonly string[], options?: NodeOptions): ExecaChildProcess
  • added: function execaNode(scriptPath: string, arguments?: readonly string[], options?: Options<null>): ExecaChildProcess<Buffer>
  • added: function execaNode(scriptPath: string, options?: Options): ExecaChildProcess
  • added: function execaNode(scriptPath: string, options?: Options<null>): ExecaChildProcess<Buffer>
  • added: function execaSync(file: string, arguments?: readonly string[], options?: SyncOptions): ExecaSyncReturnValue
  • added: function execaSync(file: string, arguments?: readonly string[], options?: SyncOptions<null>): ExecaSyncReturnValue<Buffer>
  • added: function execaSync(file: string, options?: SyncOptions): ExecaSyncReturnValue
  • added: function execaSync(file: string, options?: SyncOptions<null>): ExecaSyncReturnValue<Buffer>
  • added: interface CommonOptions<EncodingType>
  • added: interface ExecaChildPromise<StdoutErrorType>
  • added: interface ExecaError<StdoutErrorType = string> extends ExecaSyncError<StdoutErrorType>
  • added: interface ExecaReturnBase<StdoutStderrType>
  • added: interface ExecaReturnValue<StdoutErrorType = string> extends ExecaSyncReturnValue<StdoutErrorType>
  • added: interface ExecaSyncError<StdoutErrorType = string> extends Error, ExecaReturnBase<StdoutErrorType>
  • added: interface ExecaSyncReturnValue<StdoutErrorType = string> extends ExecaReturnBase<StdoutErrorType>
  • added: interface KillOptions
  • added: interface NodeOptions<EncodingType = string> extends Options<EncodingType>
  • added: interface Options<EncodingType = string> extends CommonOptions<EncodingType>
  • added: interface SyncOptions<EncodingType = string> extends CommonOptions<EncodingType>
  • added: method ExecaChildPromise.cancel(): void
  • added: method ExecaChildPromise.catch<ResultType = never>(onRejected?: (reason: ExecaError<StdoutErrorType>) => ResultType | PromiseLike<ResultType>): Promise<ExecaReturnValue<StdoutErrorType> | ResultType>
  • added: method ExecaChildPromise.kill(signal?: string, options?: KillOptions): void
  • added: property ExecaChildPromise.all?: ReadableStream
  • added: property ExecaError.all?: StdoutErrorType
  • added: property ExecaError.isCanceled: boolean
  • added: property ExecaReturnBase.command: string
  • added: property ExecaReturnBase.escapedCommand: string
  • added: property ExecaReturnBase.exitCode: number
  • added: property ExecaReturnBase.failed: boolean
  • added: property ExecaReturnBase.killed: boolean
  • added: property ExecaReturnBase.signal?: string
  • added: property ExecaReturnBase.signalDescription?: string
  • added: property ExecaReturnBase.stderr: StdoutStderrType
  • added: property ExecaReturnBase.stdout: StdoutStderrType
  • added: property ExecaReturnBase.timedOut: boolean
  • added: property ExecaReturnValue.all?: StdoutErrorType
  • added: property ExecaReturnValue.isCanceled: boolean
  • added: property ExecaSyncError.message: string
  • added: property ExecaSyncError.originalMessage?: string
  • added: property ExecaSyncError.shortMessage: string
  • added: property KillOptions.forceKillAfterTimeout?: number | false
  • added: readonly property CommonOptions.all?: boolean
  • added: readonly property CommonOptions.argv0?: string
  • added: readonly property CommonOptions.buffer?: boolean
  • added: readonly property CommonOptions.cleanup?: boolean
  • added: readonly property CommonOptions.cwd?: string | URL
  • added: readonly property CommonOptions.detached?: boolean
  • added: readonly property CommonOptions.encoding?: EncodingType
  • added: readonly property CommonOptions.env?: NodeJS.ProcessEnv
  • added: readonly property CommonOptions.execPath?: string
  • added: readonly property CommonOptions.extendEnv?: boolean
  • added: readonly property CommonOptions.gid?: number
  • added: readonly property CommonOptions.killSignal?: string | number
  • added: readonly property CommonOptions.localDir?: string | URL
  • added: readonly property CommonOptions.maxBuffer?: number
  • added: readonly property CommonOptions.preferLocal?: boolean
  • added: readonly property CommonOptions.reject?: boolean
  • added: readonly property CommonOptions.serialization?: 'json' | 'advanced'
  • added: readonly property CommonOptions.shell?: boolean | string
  • added: readonly property CommonOptions.signal?: AbortSignal
  • added: readonly property CommonOptions.stderr?: StdioOption
  • added: readonly property CommonOptions.stdin?: StdioOption
  • added: readonly property CommonOptions.stdio?: 'pipe' | 'ignore' | 'inherit' | readonly StdioOption[]
  • added: readonly property CommonOptions.stdout?: StdioOption
  • added: readonly property CommonOptions.stripFinalNewline?: boolean
  • added: readonly property CommonOptions.timeout?: number
  • added: readonly property CommonOptions.uid?: number
  • added: readonly property CommonOptions.windowsHide?: boolean
  • added: readonly property CommonOptions.windowsVerbatimArguments?: boolean
  • added: readonly property NodeOptions.nodeOptions?: string[]
  • added: readonly property NodeOptions.nodePath?: string
  • added: readonly property Options.input?: string | Buffer | ReadableStream
  • added: readonly property SyncOptions.input?: string | Buffer
  • added: type ExecaChildProcess<StdoutErrorType = string> = ChildProcess & ExecaChildPromise<StdoutErrorType> & Promise<ExecaReturnValue<StdoutErrorType>>
  • added: type StdioOption = 'pipe' | 'ipc' | 'ignore' | 'inherit' | Stream | number | undefined