@types/node 12.12.14 → 12.12.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
node/README.md CHANGED
@@ -8,7 +8,7 @@ This package contains type definitions for Node.js (http://nodejs.org/).
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Mon, 25 Nov 2019 22:58:16 GMT
11
+ * Last updated: Mon, 16 Dec 2019 12:23:00 GMT
12
12
  * Dependencies: none
13
13
  * Global values: `Buffer`, `NodeJS`, `Symbol`, `__dirname`, `__filename`, `clearImmediate`, `clearInterval`, `clearTimeout`, `console`, `exports`, `global`, `module`, `process`, `queueMicrotask`, `require`, `setImmediate`, `setInterval`, `setTimeout`
14
14
 
node/child_process.d.ts CHANGED
@@ -320,25 +320,25 @@ declare module "child_process" {
320
320
  function execFile(file: string, args: ReadonlyArray<string> | undefined | null, options: ({ encoding?: string | null } & ExecFileOptions) | undefined | null): ChildProcess;
321
321
 
322
322
  // no `options` definitely means stdout/stderr are `string`.
323
- function execFile(file: string, callback: (error: Error | null, stdout: string, stderr: string) => void): ChildProcess;
324
- function execFile(file: string, args: ReadonlyArray<string> | undefined | null, callback: (error: Error | null, stdout: string, stderr: string) => void): ChildProcess;
323
+ function execFile(file: string, callback: (error: ExecException | null, stdout: string, stderr: string) => void): ChildProcess;
324
+ function execFile(file: string, args: ReadonlyArray<string> | undefined | null, callback: (error: ExecException | null, stdout: string, stderr: string) => void): ChildProcess;
325
325
 
326
326
  // `options` with `"buffer"` or `null` for `encoding` means stdout/stderr are definitely `Buffer`.
327
- function execFile(file: string, options: ExecFileOptionsWithBufferEncoding, callback: (error: Error | null, stdout: Buffer, stderr: Buffer) => void): ChildProcess;
327
+ function execFile(file: string, options: ExecFileOptionsWithBufferEncoding, callback: (error: ExecException | null, stdout: Buffer, stderr: Buffer) => void): ChildProcess;
328
328
  function execFile(
329
329
  file: string,
330
330
  args: ReadonlyArray<string> | undefined | null,
331
331
  options: ExecFileOptionsWithBufferEncoding,
332
- callback: (error: Error | null, stdout: Buffer, stderr: Buffer) => void,
332
+ callback: (error: ExecException | null, stdout: Buffer, stderr: Buffer) => void,
333
333
  ): ChildProcess;
334
334
 
335
335
  // `options` with well known `encoding` means stdout/stderr are definitely `string`.
336
- function execFile(file: string, options: ExecFileOptionsWithStringEncoding, callback: (error: Error | null, stdout: string, stderr: string) => void): ChildProcess;
336
+ function execFile(file: string, options: ExecFileOptionsWithStringEncoding, callback: (error: ExecException | null, stdout: string, stderr: string) => void): ChildProcess;
337
337
  function execFile(
338
338
  file: string,
339
339
  args: ReadonlyArray<string> | undefined | null,
340
340
  options: ExecFileOptionsWithStringEncoding,
341
- callback: (error: Error | null, stdout: string, stderr: string) => void,
341
+ callback: (error: ExecException | null, stdout: string, stderr: string) => void,
342
342
  ): ChildProcess;
343
343
 
344
344
  // `options` with an `encoding` whose type is `string` means stdout/stderr could either be `Buffer` or `string`.
@@ -346,30 +346,35 @@ declare module "child_process" {
346
346
  function execFile(
347
347
  file: string,
348
348
  options: ExecFileOptionsWithOtherEncoding,
349
- callback: (error: Error | null, stdout: string | Buffer, stderr: string | Buffer) => void,
349
+ callback: (error: ExecException | null, stdout: string | Buffer, stderr: string | Buffer) => void,
350
350
  ): ChildProcess;
351
351
  function execFile(
352
352
  file: string,
353
353
  args: ReadonlyArray<string> | undefined | null,
354
354
  options: ExecFileOptionsWithOtherEncoding,
355
- callback: (error: Error | null, stdout: string | Buffer, stderr: string | Buffer) => void,
355
+ callback: (error: ExecException | null, stdout: string | Buffer, stderr: string | Buffer) => void,
356
356
  ): ChildProcess;
357
357
 
358
358
  // `options` without an `encoding` means stdout/stderr are definitely `string`.
359
- function execFile(file: string, options: ExecFileOptions, callback: (error: Error | null, stdout: string, stderr: string) => void): ChildProcess;
360
- function execFile(file: string, args: ReadonlyArray<string> | undefined | null, options: ExecFileOptions, callback: (error: Error | null, stdout: string, stderr: string) => void): ChildProcess;
359
+ function execFile(file: string, options: ExecFileOptions, callback: (error: ExecException | null, stdout: string, stderr: string) => void): ChildProcess;
360
+ function execFile(
361
+ file: string,
362
+ args: ReadonlyArray<string> | undefined | null,
363
+ options: ExecFileOptions,
364
+ callback: (error: ExecException | null, stdout: string, stderr: string) => void
365
+ ): ChildProcess;
361
366
 
362
367
  // fallback if nothing else matches. Worst case is always `string | Buffer`.
363
368
  function execFile(
364
369
  file: string,
365
370
  options: ({ encoding?: string | null } & ExecFileOptions) | undefined | null,
366
- callback: ((error: Error | null, stdout: string | Buffer, stderr: string | Buffer) => void) | undefined | null,
371
+ callback: ((error: ExecException | null, stdout: string | Buffer, stderr: string | Buffer) => void) | undefined | null,
367
372
  ): ChildProcess;
368
373
  function execFile(
369
374
  file: string,
370
375
  args: ReadonlyArray<string> | undefined | null,
371
376
  options: ({ encoding?: string | null } & ExecFileOptions) | undefined | null,
372
- callback: ((error: Error | null, stdout: string | Buffer, stderr: string | Buffer) => void) | undefined | null,
377
+ callback: ((error: ExecException | null, stdout: string | Buffer, stderr: string | Buffer) => void) | undefined | null,
373
378
  ): ChildProcess;
374
379
 
375
380
  // NOTE: This namespace provides design-time support for util.promisify. Exported members do not exist at runtime.
node/fs.d.ts CHANGED
@@ -107,22 +107,27 @@ declare module "fs" {
107
107
  addListener(event: string, listener: (...args: any[]) => void): this;
108
108
  addListener(event: "change", listener: (eventType: string, filename: string | Buffer) => void): this;
109
109
  addListener(event: "error", listener: (error: Error) => void): this;
110
+ addListener(event: "close", listener: () => void): this;
110
111
 
111
112
  on(event: string, listener: (...args: any[]) => void): this;
112
113
  on(event: "change", listener: (eventType: string, filename: string | Buffer) => void): this;
113
114
  on(event: "error", listener: (error: Error) => void): this;
115
+ on(event: "close", listener: () => void): this;
114
116
 
115
117
  once(event: string, listener: (...args: any[]) => void): this;
116
118
  once(event: "change", listener: (eventType: string, filename: string | Buffer) => void): this;
117
119
  once(event: "error", listener: (error: Error) => void): this;
120
+ once(event: "close", listener: () => void): this;
118
121
 
119
122
  prependListener(event: string, listener: (...args: any[]) => void): this;
120
123
  prependListener(event: "change", listener: (eventType: string, filename: string | Buffer) => void): this;
121
124
  prependListener(event: "error", listener: (error: Error) => void): this;
125
+ prependListener(event: "close", listener: () => void): this;
122
126
 
123
127
  prependOnceListener(event: string, listener: (...args: any[]) => void): this;
124
128
  prependOnceListener(event: "change", listener: (eventType: string, filename: string | Buffer) => void): this;
125
129
  prependOnceListener(event: "error", listener: (error: Error) => void): this;
130
+ prependOnceListener(event: "close", listener: () => void): this;
126
131
  }
127
132
 
128
133
  class ReadStream extends stream.Readable {
node/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "12.12.14",
3
+ "version": "12.12.18",
4
4
  "description": "TypeScript definitions for Node.js",
5
5
  "license": "MIT",
6
6
  "contributors": [
@@ -226,6 +226,6 @@
226
226
  },
227
227
  "scripts": {},
228
228
  "dependencies": {},
229
- "typesPublisherContentHash": "305a8ff81632f0e70287898475e87d6aedbd683a5e37cb775f9ea845625cfa06",
229
+ "typesPublisherContentHash": "f6cb4052c479e4a03acc8c38e4377d320c93a8093b1ecc412b9b9606a18aeee5",
230
230
  "typeScriptVersion": "2.8"
231
231
  }
node/querystring.d.ts CHANGED
@@ -11,7 +11,7 @@ declare module "querystring" {
11
11
  interface ParsedUrlQuery { [key: string]: string | string[]; }
12
12
 
13
13
  interface ParsedUrlQueryInput {
14
- [key: string]: NodeJS.PoorMansUnknown;
14
+ [key: string]: string | number | boolean | string[] | number[] | boolean[];
15
15
  }
16
16
 
17
17
  function stringify(obj?: ParsedUrlQueryInput, sep?: string, eq?: string, options?: StringifyOptions): string;
node/readline.d.ts CHANGED
@@ -13,6 +13,13 @@ declare module "readline" {
13
13
  class Interface extends events.EventEmitter {
14
14
  readonly terminal: boolean;
15
15
 
16
+ // Need direct access to line/cursor data, for use in external processes
17
+ // see: https://github.com/nodejs/node/issues/30347
18
+ /** The current input data */
19
+ readonly line: string;
20
+ /** The current cursor position in the input line */
21
+ readonly cursor: number;
22
+
16
23
  /**
17
24
  * NOTE: According to the documentation:
18
25
  *