index.d.ts: Allow 2 or 1 parameter exec() call. Fix callback parameter types

This commit is contained in:
Filip Budiša 2019-12-18 19:11:38 +01:00
parent 91df887427
commit 0ae7ed8ff4

5
index.d.ts vendored
View file

@ -1 +1,4 @@
export function exec(cmd: string, options: { name?: string, icns?: string, env?: { [key: string]: string } }, callback: (error: string, stdout: string, stderr: string) => void): void; export function exec(cmd: string,
options?: ((error?: Error, stdout?: string | Buffer, stderr?: string | Buffer) => void)
| { name?: string, icns?: string, env?: { [key: string]: string } },
callback?: (error: Error, stdout: string | Buffer, stderr: string | Buffer) => void): void;