Interface: ProcessExecOptions
Defined in: packages/sdk/src/process-service.ts:87
Options for ProcessService.exec.
Properties
cwd?
optional cwd?: string;Defined in: packages/sdk/src/process-service.ts:95
Working directory to run the command in. Defaults to the open workspace folder when omitted — the right cwd for CLI tools (git, formatters, linters) that operate on a repo. A cwd outside the workspace throws PathDeniedError unless the extension declared the processPermission. First-party (bundled) extensions are unscoped.
env?
optional env?: Record<string, string>;Defined in: packages/sdk/src/process-service.ts:106
Extra environment variables, merged over the host's environment (the command inherits the host env; these keys add to or override it). Use it to set things like GIT_PAGER=cat or a locale without clobbering PATH.
Keys beginning SILO_ (and the bare SILO) are reserved by the host and are dropped — same rule as ProcessSpawnOptions.env, so the reservation can't be sidestepped by launching through exec instead of spawn.
timeoutMs?
optional timeoutMs?: number;Defined in: packages/sdk/src/process-service.ts:112
Kill the process and reject after this many milliseconds. The whole process group is terminated (not just the direct child), so shell wrappers don't leak orphans. The rejection is an Error whose name is "AbortError".
signal?
optional signal?: AbortSignal;Defined in: packages/sdk/src/process-service.ts:118
Abort handle. Aborting kills the process (and its group) and rejects the exec promise with an Error whose name is "AbortError" — the same shape as a timeoutMs expiry, so callers branch on err.name.