# @types/npmcli__promise-spawn

> TypeScript definitions for @npmcli/promise-spawn

Latest version **6.0.3** (published 2023-11-07) · MIT license · 0 weekly downloads

## Install

```sh
npm install @types/npmcli__promise-spawn
pnpm add @types/npmcli__promise-spawn
yarn add @types/npmcli__promise-spawn
bun add @types/npmcli__promise-spawn
```

## Health

**Score 45/100 (D)** — status: abandoned.

Positive: has types; no vulnerabilities; high maintenance score; popular repo; extremely popular.

Warnings: low downloads; no esm support.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 6.0.3 |
| Published | 2023-11-07 |
| First published | 2022-12-12 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 4.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 51432 |
| Maintainers | types |

## Links

- npm: https://www.npmjs.com/package/@types/npmcli__promise-spawn
- Repository: https://github.com/DefinitelyTyped/DefinitelyTyped
- Homepage: https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/npmcli__promise-spawn
- npm.io page: https://npm.io/package/@types/npmcli__promise-spawn

## Dependencies (1)

- [@types/node](https://npm.io/package/@types/node.md) *

## Recent versions

- 6.0.3 (latest) — 2023-11-07
- 6.0.0 (ts4.2) — 2022-12-12
- 6.0.2 — 2023-10-18
- 6.0.1 — 2023-09-23

## README

# Installation
> `npm install --save @types/npmcli__promise-spawn`

# Summary
This package contains type definitions for @npmcli/promise-spawn (https://github.com/npm/promise-spawn#readme).

# Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/npmcli__promise-spawn.
## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/npmcli__promise-spawn/index.d.ts)
````ts
/// <reference types="node" />

import { spawn, SpawnOptions } from "child_process";

type NativeSpawnResult = ReturnType<typeof spawn>;

type SpawnResult<Output, Extra> =
    & Promise<
        {
            cmd: string;
            args: string[];
            code: number;
            signal: NodeJS.Signals | null;
            stdout: Output;
            stderr: Output;
        } & Extra
    >
    & { process: NativeSpawnResult; stdio: NativeSpawnResult["stdio"] };

type PromiseSpawnOptions = {
    cwd?: string;
    stdioString?: boolean;
} & SpawnOptions;

declare const promiseSpawn: {
    <O extends PromiseSpawnOptions = PromiseSpawnOptions>(
        cmd: string,
        args: string[],
        opts?: O,
        extra?: Record<any, any>,
    ): SpawnResult<O extends { stdioString: false } ? Buffer : string, typeof extra>;
    open<O extends PromiseSpawnOptions & { command?: string } = PromiseSpawnOptions & { command?: string }>(
        args: string | string[],
        opts?: O,
        extra?: Record<any, any>,
    ): SpawnResult<O extends { stdioString: false } ? Buffer : string, typeof extra>;
};

export = promiseSpawn;

````

### Additional Details
 * Last updated: Tue, 07 Nov 2023 09:09:39 GMT
 * Dependencies: [@types/node](https://npmjs.com/package/@types/node)

# Credits
These definitions were written by [Anton Golub](https://github.com/antongolub).

---
_Source: https://npm.io/package/@types/npmcli__promise-spawn · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
