cloudstructs 0.1.41 → 0.2.2
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.
- package/.gitattributes +19 -19
- package/.jsii +2754 -1559
- package/API.md +77 -77
- package/README.md +2 -3
- package/lib/codecommit-mirror/index.d.ts +6 -6
- package/lib/codecommit-mirror/index.js +13 -12
- package/lib/ecs-service-roller/index.d.ts +5 -5
- package/lib/ecs-service-roller/index.js +10 -9
- package/lib/email-receiver/receiver.d.ts +5 -5
- package/lib/email-receiver/receiver.js +15 -14
- package/lib/saml-identity-provider/index.d.ts +18 -18
- package/lib/saml-identity-provider/index.js +16 -15
- package/lib/slack-events/index.d.ts +5 -4
- package/lib/slack-events/index.js +13 -14
- package/lib/slack-textract/index.d.ts +6 -5
- package/lib/slack-textract/index.js +12 -11
- package/lib/state-machine-cr-provider/index.d.ts +2 -1
- package/lib/state-machine-cr-provider/index.js +14 -13
- package/lib/static-website/index.d.ts +6 -6
- package/lib/static-website/index.js +16 -15
- package/lib/url-shortener/index.d.ts +8 -7
- package/lib/url-shortener/index.js +19 -18
- package/node_modules/@slack/logger/node_modules/@types/node/README.md +2 -2
- package/node_modules/@slack/logger/node_modules/@types/node/buffer.d.ts +1 -1
- package/node_modules/@slack/logger/node_modules/@types/node/child_process.d.ts +19 -16
- package/node_modules/@slack/logger/node_modules/@types/node/console.d.ts +5 -0
- package/node_modules/@slack/logger/node_modules/@types/node/crypto.d.ts +51 -3
- package/node_modules/@slack/logger/node_modules/@types/node/dgram.d.ts +8 -8
- package/node_modules/@slack/logger/node_modules/@types/node/diagnostics_channel.d.ts +6 -0
- package/node_modules/@slack/logger/node_modules/@types/node/dns/promises.d.ts +11 -0
- package/node_modules/@slack/logger/node_modules/@types/node/dns.d.ts +11 -0
- package/node_modules/@slack/logger/node_modules/@types/node/fs/promises.d.ts +90 -3
- package/node_modules/@slack/logger/node_modules/@types/node/fs.d.ts +92 -39
- package/node_modules/@slack/logger/node_modules/@types/node/http.d.ts +17 -6
- package/node_modules/@slack/logger/node_modules/@types/node/index.d.ts +2 -3
- package/node_modules/@slack/logger/node_modules/@types/node/inspector.d.ts +7 -0
- package/node_modules/@slack/logger/node_modules/@types/node/net.d.ts +2 -2
- package/node_modules/@slack/logger/node_modules/@types/node/package.json +8 -13
- package/node_modules/@slack/logger/node_modules/@types/node/process.d.ts +5 -1
- package/node_modules/@slack/logger/node_modules/@types/node/readline.d.ts +1 -0
- package/node_modules/@slack/logger/node_modules/@types/node/stream/web.d.ts +385 -0
- package/node_modules/@slack/logger/node_modules/@types/node/stream.d.ts +26 -6
- package/node_modules/@slack/logger/node_modules/@types/node/tty.d.ts +1 -3
- package/node_modules/@slack/logger/node_modules/@types/node/url.d.ts +24 -1
- package/node_modules/@slack/logger/node_modules/@types/node/util.d.ts +31 -0
- package/node_modules/@slack/web-api/node_modules/@types/node/README.md +2 -2
- package/node_modules/@slack/web-api/node_modules/@types/node/buffer.d.ts +1 -1
- package/node_modules/@slack/web-api/node_modules/@types/node/child_process.d.ts +19 -16
- package/node_modules/@slack/web-api/node_modules/@types/node/console.d.ts +5 -0
- package/node_modules/@slack/web-api/node_modules/@types/node/crypto.d.ts +51 -3
- package/node_modules/@slack/web-api/node_modules/@types/node/dgram.d.ts +8 -8
- package/node_modules/@slack/web-api/node_modules/@types/node/diagnostics_channel.d.ts +6 -0
- package/node_modules/@slack/web-api/node_modules/@types/node/dns/promises.d.ts +11 -0
- package/node_modules/@slack/web-api/node_modules/@types/node/dns.d.ts +11 -0
- package/node_modules/@slack/web-api/node_modules/@types/node/fs/promises.d.ts +90 -3
- package/node_modules/@slack/web-api/node_modules/@types/node/fs.d.ts +92 -39
- package/node_modules/@slack/web-api/node_modules/@types/node/http.d.ts +17 -6
- package/node_modules/@slack/web-api/node_modules/@types/node/index.d.ts +2 -3
- package/node_modules/@slack/web-api/node_modules/@types/node/inspector.d.ts +7 -0
- package/node_modules/@slack/web-api/node_modules/@types/node/net.d.ts +2 -2
- package/node_modules/@slack/web-api/node_modules/@types/node/package.json +8 -13
- package/node_modules/@slack/web-api/node_modules/@types/node/process.d.ts +5 -1
- package/node_modules/@slack/web-api/node_modules/@types/node/readline.d.ts +1 -0
- package/node_modules/@slack/web-api/node_modules/@types/node/stream/web.d.ts +385 -0
- package/node_modules/@slack/web-api/node_modules/@types/node/stream.d.ts +26 -6
- package/node_modules/@slack/web-api/node_modules/@types/node/tty.d.ts +1 -3
- package/node_modules/@slack/web-api/node_modules/@types/node/url.d.ts +24 -1
- package/node_modules/@slack/web-api/node_modules/@types/node/util.d.ts +31 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/README.md +2 -2
- package/node_modules/@types/cacheable-request/node_modules/@types/node/buffer.d.ts +1 -1
- package/node_modules/@types/cacheable-request/node_modules/@types/node/child_process.d.ts +19 -16
- package/node_modules/@types/cacheable-request/node_modules/@types/node/console.d.ts +5 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/crypto.d.ts +51 -3
- package/node_modules/@types/cacheable-request/node_modules/@types/node/dgram.d.ts +8 -8
- package/node_modules/@types/cacheable-request/node_modules/@types/node/diagnostics_channel.d.ts +6 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/dns/promises.d.ts +11 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/dns.d.ts +11 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/fs/promises.d.ts +90 -3
- package/node_modules/@types/cacheable-request/node_modules/@types/node/fs.d.ts +92 -39
- package/node_modules/@types/cacheable-request/node_modules/@types/node/http.d.ts +17 -6
- package/node_modules/@types/cacheable-request/node_modules/@types/node/index.d.ts +2 -3
- package/node_modules/@types/cacheable-request/node_modules/@types/node/inspector.d.ts +7 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/net.d.ts +2 -2
- package/node_modules/@types/cacheable-request/node_modules/@types/node/package.json +8 -13
- package/node_modules/@types/cacheable-request/node_modules/@types/node/process.d.ts +5 -1
- package/node_modules/@types/cacheable-request/node_modules/@types/node/readline.d.ts +1 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/stream/web.d.ts +385 -0
- package/node_modules/@types/cacheable-request/node_modules/@types/node/stream.d.ts +26 -6
- package/node_modules/@types/cacheable-request/node_modules/@types/node/tty.d.ts +1 -3
- package/node_modules/@types/cacheable-request/node_modules/@types/node/url.d.ts +24 -1
- package/node_modules/@types/cacheable-request/node_modules/@types/node/util.d.ts +31 -0
- package/node_modules/@types/is-stream/node_modules/@types/node/README.md +2 -2
- package/node_modules/@types/is-stream/node_modules/@types/node/buffer.d.ts +1 -1
- package/node_modules/@types/is-stream/node_modules/@types/node/child_process.d.ts +19 -16
- package/node_modules/@types/is-stream/node_modules/@types/node/console.d.ts +5 -0
- package/node_modules/@types/is-stream/node_modules/@types/node/crypto.d.ts +51 -3
- package/node_modules/@types/is-stream/node_modules/@types/node/dgram.d.ts +8 -8
- package/node_modules/@types/is-stream/node_modules/@types/node/diagnostics_channel.d.ts +6 -0
- package/node_modules/@types/is-stream/node_modules/@types/node/dns/promises.d.ts +11 -0
- package/node_modules/@types/is-stream/node_modules/@types/node/dns.d.ts +11 -0
- package/node_modules/@types/is-stream/node_modules/@types/node/fs/promises.d.ts +90 -3
- package/node_modules/@types/is-stream/node_modules/@types/node/fs.d.ts +92 -39
- package/node_modules/@types/is-stream/node_modules/@types/node/http.d.ts +17 -6
- package/node_modules/@types/is-stream/node_modules/@types/node/index.d.ts +2 -3
- package/node_modules/@types/is-stream/node_modules/@types/node/inspector.d.ts +7 -0
- package/node_modules/@types/is-stream/node_modules/@types/node/net.d.ts +2 -2
- package/node_modules/@types/is-stream/node_modules/@types/node/package.json +8 -13
- package/node_modules/@types/is-stream/node_modules/@types/node/process.d.ts +5 -1
- package/node_modules/@types/is-stream/node_modules/@types/node/readline.d.ts +1 -0
- package/node_modules/@types/is-stream/node_modules/@types/node/stream/web.d.ts +385 -0
- package/node_modules/@types/is-stream/node_modules/@types/node/stream.d.ts +26 -6
- package/node_modules/@types/is-stream/node_modules/@types/node/tty.d.ts +1 -3
- package/node_modules/@types/is-stream/node_modules/@types/node/url.d.ts +24 -1
- package/node_modules/@types/is-stream/node_modules/@types/node/util.d.ts +31 -0
- package/node_modules/@types/keyv/node_modules/@types/node/README.md +2 -2
- package/node_modules/@types/keyv/node_modules/@types/node/buffer.d.ts +1 -1
- package/node_modules/@types/keyv/node_modules/@types/node/child_process.d.ts +19 -16
- package/node_modules/@types/keyv/node_modules/@types/node/console.d.ts +5 -0
- package/node_modules/@types/keyv/node_modules/@types/node/crypto.d.ts +51 -3
- package/node_modules/@types/keyv/node_modules/@types/node/dgram.d.ts +8 -8
- package/node_modules/@types/keyv/node_modules/@types/node/diagnostics_channel.d.ts +6 -0
- package/node_modules/@types/keyv/node_modules/@types/node/dns/promises.d.ts +11 -0
- package/node_modules/@types/keyv/node_modules/@types/node/dns.d.ts +11 -0
- package/node_modules/@types/keyv/node_modules/@types/node/fs/promises.d.ts +90 -3
- package/node_modules/@types/keyv/node_modules/@types/node/fs.d.ts +92 -39
- package/node_modules/@types/keyv/node_modules/@types/node/http.d.ts +17 -6
- package/node_modules/@types/keyv/node_modules/@types/node/index.d.ts +2 -3
- package/node_modules/@types/keyv/node_modules/@types/node/inspector.d.ts +7 -0
- package/node_modules/@types/keyv/node_modules/@types/node/net.d.ts +2 -2
- package/node_modules/@types/keyv/node_modules/@types/node/package.json +8 -13
- package/node_modules/@types/keyv/node_modules/@types/node/process.d.ts +5 -1
- package/node_modules/@types/keyv/node_modules/@types/node/readline.d.ts +1 -0
- package/node_modules/@types/keyv/node_modules/@types/node/stream/web.d.ts +385 -0
- package/node_modules/@types/keyv/node_modules/@types/node/stream.d.ts +26 -6
- package/node_modules/@types/keyv/node_modules/@types/node/tty.d.ts +1 -3
- package/node_modules/@types/keyv/node_modules/@types/node/url.d.ts +24 -1
- package/node_modules/@types/keyv/node_modules/@types/node/util.d.ts +31 -0
- package/node_modules/@types/responselike/node_modules/@types/node/README.md +2 -2
- package/node_modules/@types/responselike/node_modules/@types/node/buffer.d.ts +1 -1
- package/node_modules/@types/responselike/node_modules/@types/node/child_process.d.ts +19 -16
- package/node_modules/@types/responselike/node_modules/@types/node/console.d.ts +5 -0
- package/node_modules/@types/responselike/node_modules/@types/node/crypto.d.ts +51 -3
- package/node_modules/@types/responselike/node_modules/@types/node/dgram.d.ts +8 -8
- package/node_modules/@types/responselike/node_modules/@types/node/diagnostics_channel.d.ts +6 -0
- package/node_modules/@types/responselike/node_modules/@types/node/dns/promises.d.ts +11 -0
- package/node_modules/@types/responselike/node_modules/@types/node/dns.d.ts +11 -0
- package/node_modules/@types/responselike/node_modules/@types/node/fs/promises.d.ts +90 -3
- package/node_modules/@types/responselike/node_modules/@types/node/fs.d.ts +92 -39
- package/node_modules/@types/responselike/node_modules/@types/node/http.d.ts +17 -6
- package/node_modules/@types/responselike/node_modules/@types/node/index.d.ts +2 -3
- package/node_modules/@types/responselike/node_modules/@types/node/inspector.d.ts +7 -0
- package/node_modules/@types/responselike/node_modules/@types/node/net.d.ts +2 -2
- package/node_modules/@types/responselike/node_modules/@types/node/package.json +8 -13
- package/node_modules/@types/responselike/node_modules/@types/node/process.d.ts +5 -1
- package/node_modules/@types/responselike/node_modules/@types/node/readline.d.ts +1 -0
- package/node_modules/@types/responselike/node_modules/@types/node/stream/web.d.ts +385 -0
- package/node_modules/@types/responselike/node_modules/@types/node/stream.d.ts +26 -6
- package/node_modules/@types/responselike/node_modules/@types/node/tty.d.ts +1 -3
- package/node_modules/@types/responselike/node_modules/@types/node/url.d.ts +24 -1
- package/node_modules/@types/responselike/node_modules/@types/node/util.d.ts +31 -0
- package/node_modules/follow-redirects/index.js +45 -14
- package/node_modules/follow-redirects/package.json +1 -1
- package/node_modules/got/dist/source/as-promise/parse-body.d.ts +1 -1
- package/node_modules/got/dist/source/as-promise/types.js +2 -0
- package/node_modules/got/dist/source/core/index.d.ts +1 -1
- package/node_modules/got/dist/source/core/index.js +9 -3
- package/node_modules/got/dist/source/types.d.ts +14 -12
- package/node_modules/got/package.json +2 -2
- package/node_modules/got/readme.md +11 -10
- package/node_modules/keyv/LICENSE +1 -1
- package/node_modules/keyv/README.md +12 -10
- package/node_modules/keyv/package.json +17 -12
- package/node_modules/keyv/src/index.js +14 -16
- package/node_modules/mime-db/HISTORY.md +13 -0
- package/node_modules/mime-db/db.json +54 -0
- package/node_modules/mime-db/package.json +7 -7
- package/node_modules/mime-types/HISTORY.md +13 -3
- package/node_modules/mime-types/package.json +7 -7
- package/package.json +29 -80
|
@@ -260,6 +260,29 @@ declare module 'fs' {
|
|
|
260
260
|
*/
|
|
261
261
|
readSync(): Dirent | null;
|
|
262
262
|
}
|
|
263
|
+
/**
|
|
264
|
+
* Class: fs.StatWatcher
|
|
265
|
+
* @since v14.3.0, v12.20.0
|
|
266
|
+
* Extends `EventEmitter`
|
|
267
|
+
* A successful call to {@link watchFile} method will return a new fs.StatWatcher object.
|
|
268
|
+
*/
|
|
269
|
+
export interface StatWatcher extends EventEmitter {
|
|
270
|
+
/**
|
|
271
|
+
* @since v14.3.0, v12.20.0
|
|
272
|
+
* When called, requests that the Node.js event loop not exit so long as the `fs.StatWatcher` is active.
|
|
273
|
+
* Calling `watcher.ref()` multiple times will have no effect.
|
|
274
|
+
* By default, all `fs.StatWatcher`` objects are "ref'ed", making it normally unnecessary to call `watcher.ref()`
|
|
275
|
+
* unless `watcher.unref()` had been called previously.
|
|
276
|
+
*/
|
|
277
|
+
ref(): this;
|
|
278
|
+
/**
|
|
279
|
+
* @since v14.3.0, v12.20.0
|
|
280
|
+
* When called, the active `fs.StatWatcher`` object will not require the Node.js event loop to remain active.
|
|
281
|
+
* If there is no other activity keeping the event loop running, the process may exit before the `fs.StatWatcher`` object's callback is invoked.
|
|
282
|
+
* `Calling watcher.unref()` multiple times will have no effect.
|
|
283
|
+
*/
|
|
284
|
+
unref(): this;
|
|
285
|
+
}
|
|
263
286
|
export interface FSWatcher extends EventEmitter {
|
|
264
287
|
/**
|
|
265
288
|
* Stop watching for changes on the given `fs.FSWatcher`. Once stopped, the `fs.FSWatcher` object is no longer usable.
|
|
@@ -297,7 +320,7 @@ declare module 'fs' {
|
|
|
297
320
|
* @since v0.1.93
|
|
298
321
|
*/
|
|
299
322
|
export class ReadStream extends stream.Readable {
|
|
300
|
-
close(): void;
|
|
323
|
+
close(callback?: (err?: NodeJS.ErrnoException | null) => void): void;
|
|
301
324
|
/**
|
|
302
325
|
* The number of bytes that have been read so far.
|
|
303
326
|
* @since v6.4.0
|
|
@@ -306,7 +329,7 @@ declare module 'fs' {
|
|
|
306
329
|
/**
|
|
307
330
|
* The path to the file the stream is reading from as specified in the first
|
|
308
331
|
* argument to `fs.createReadStream()`. If `path` is passed as a string, then`readStream.path` will be a string. If `path` is passed as a `Buffer`, then`readStream.path` will be a
|
|
309
|
-
* `Buffer`.
|
|
332
|
+
* `Buffer`. If `fd` is specified, then`readStream.path` will be `undefined`.
|
|
310
333
|
* @since v0.1.93
|
|
311
334
|
*/
|
|
312
335
|
path: string | Buffer;
|
|
@@ -385,7 +408,7 @@ declare module 'fs' {
|
|
|
385
408
|
* callback that will be executed once the `writeStream`is closed.
|
|
386
409
|
* @since v0.9.4
|
|
387
410
|
*/
|
|
388
|
-
close(): void;
|
|
411
|
+
close(callback?: (err?: NodeJS.ErrnoException | null) => void): void;
|
|
389
412
|
/**
|
|
390
413
|
* The number of bytes written so far. Does not include data that is still queued
|
|
391
414
|
* for writing.
|
|
@@ -768,6 +791,7 @@ declare module 'fs' {
|
|
|
768
791
|
* @deprecated Since v0.4.7
|
|
769
792
|
*/
|
|
770
793
|
export function lchmod(path: PathLike, mode: Mode, callback: NoParamCallback): void;
|
|
794
|
+
/** @deprecated */
|
|
771
795
|
export namespace lchmod {
|
|
772
796
|
/**
|
|
773
797
|
* Asynchronous lchmod(2) - Change permissions of a file. Does not dereference symbolic links.
|
|
@@ -904,42 +928,42 @@ declare module 'fs' {
|
|
|
904
928
|
): Promise<BigIntStats>;
|
|
905
929
|
function __promisify__(path: PathLike, options?: StatOptions): Promise<Stats | BigIntStats>;
|
|
906
930
|
}
|
|
907
|
-
export interface StatSyncFn
|
|
908
|
-
(path:
|
|
931
|
+
export interface StatSyncFn extends Function {
|
|
932
|
+
(path: PathLike, options?: undefined): Stats;
|
|
909
933
|
(
|
|
910
|
-
path:
|
|
911
|
-
options?:
|
|
934
|
+
path: PathLike,
|
|
935
|
+
options?: StatSyncOptions & {
|
|
912
936
|
bigint?: false | undefined;
|
|
913
937
|
throwIfNoEntry: false;
|
|
914
938
|
}
|
|
915
939
|
): Stats | undefined;
|
|
916
940
|
(
|
|
917
|
-
path:
|
|
918
|
-
options:
|
|
941
|
+
path: PathLike,
|
|
942
|
+
options: StatSyncOptions & {
|
|
919
943
|
bigint: true;
|
|
920
944
|
throwIfNoEntry: false;
|
|
921
945
|
}
|
|
922
946
|
): BigIntStats | undefined;
|
|
923
947
|
(
|
|
924
|
-
path:
|
|
925
|
-
options?:
|
|
948
|
+
path: PathLike,
|
|
949
|
+
options?: StatSyncOptions & {
|
|
926
950
|
bigint?: false | undefined;
|
|
927
951
|
}
|
|
928
952
|
): Stats;
|
|
929
953
|
(
|
|
930
|
-
path:
|
|
931
|
-
options:
|
|
954
|
+
path: PathLike,
|
|
955
|
+
options: StatSyncOptions & {
|
|
932
956
|
bigint: true;
|
|
933
957
|
}
|
|
934
958
|
): BigIntStats;
|
|
935
959
|
(
|
|
936
|
-
path:
|
|
937
|
-
options:
|
|
960
|
+
path: PathLike,
|
|
961
|
+
options: StatSyncOptions & {
|
|
938
962
|
bigint: boolean;
|
|
939
963
|
throwIfNoEntry?: false | undefined;
|
|
940
964
|
}
|
|
941
965
|
): Stats | BigIntStats;
|
|
942
|
-
(path:
|
|
966
|
+
(path: PathLike, options?: StatSyncOptions): Stats | BigIntStats | undefined;
|
|
943
967
|
}
|
|
944
968
|
/**
|
|
945
969
|
* Synchronous stat(2) - Get file status.
|
|
@@ -993,7 +1017,20 @@ declare module 'fs' {
|
|
|
993
1017
|
* Synchronous fstat(2) - Get file status.
|
|
994
1018
|
* @param fd A file descriptor.
|
|
995
1019
|
*/
|
|
996
|
-
export
|
|
1020
|
+
export function fstatSync(
|
|
1021
|
+
fd: number,
|
|
1022
|
+
options?: StatOptions & {
|
|
1023
|
+
bigint?: false | undefined;
|
|
1024
|
+
}
|
|
1025
|
+
): Stats;
|
|
1026
|
+
export function fstatSync(
|
|
1027
|
+
fd: number,
|
|
1028
|
+
options: StatOptions & {
|
|
1029
|
+
bigint: true;
|
|
1030
|
+
}
|
|
1031
|
+
): BigIntStats;
|
|
1032
|
+
export function fstatSync(fd: number, options?: StatOptions): Stats | BigIntStats;
|
|
1033
|
+
|
|
997
1034
|
/**
|
|
998
1035
|
* Retrieves the `fs.Stats` for the symbolic link referred to by the path.
|
|
999
1036
|
* The callback gets two arguments `(err, stats)` where `stats` is a `fs.Stats` object. `lstat()` is identical to `stat()`, except that if `path` is a symbolic
|
|
@@ -1456,7 +1493,7 @@ declare module 'fs' {
|
|
|
1456
1493
|
* Asynchronously creates a directory.
|
|
1457
1494
|
*
|
|
1458
1495
|
* The callback is given a possible exception and, if `recursive` is `true`, the
|
|
1459
|
-
* first directory path created, `(err,
|
|
1496
|
+
* first directory path created, `(err[, path])`.`path` can still be `undefined` when `recursive` is `true`, if no directory was
|
|
1460
1497
|
* created.
|
|
1461
1498
|
*
|
|
1462
1499
|
* The optional `options` argument can be an integer specifying `mode` (permission
|
|
@@ -2202,9 +2239,9 @@ declare module 'fs' {
|
|
|
2202
2239
|
* If this method is invoked as its `util.promisify()` ed version, it returns
|
|
2203
2240
|
* a promise for an `Object` with `bytesRead` and `buffer` properties.
|
|
2204
2241
|
* @since v0.0.2
|
|
2205
|
-
* @param
|
|
2206
|
-
* @param
|
|
2207
|
-
* @param
|
|
2242
|
+
* @param buffer The buffer that the data will be written to.
|
|
2243
|
+
* @param offset The position in `buffer` to write the data to.
|
|
2244
|
+
* @param length The number of bytes to read.
|
|
2208
2245
|
* @param position Specifies where to begin reading from in the file. If `position` is `null` or `-1 `, data will be read from the current file position, and the file position will be updated. If
|
|
2209
2246
|
* `position` is an integer, the file position will be unchanged.
|
|
2210
2247
|
*/
|
|
@@ -2749,7 +2786,7 @@ declare module 'fs' {
|
|
|
2749
2786
|
* the numeric values in these objects are specified as `BigInt`s.
|
|
2750
2787
|
*
|
|
2751
2788
|
* To be notified when the file was modified, not just accessed, it is necessary
|
|
2752
|
-
* to compare `curr.
|
|
2789
|
+
* to compare `curr.mtimeMs` and `prev.mtimeMs`.
|
|
2753
2790
|
*
|
|
2754
2791
|
* When an `fs.watchFile` operation results in an `ENOENT` error, it
|
|
2755
2792
|
* will invoke the listener once, with all the fields zeroed (or, for dates, the
|
|
@@ -2770,21 +2807,34 @@ declare module 'fs' {
|
|
|
2770
2807
|
* * the file is renamed and then renamed a second time back to its original name
|
|
2771
2808
|
* @since v0.1.31
|
|
2772
2809
|
*/
|
|
2810
|
+
export interface WatchFileOptions {
|
|
2811
|
+
bigint?: boolean | undefined;
|
|
2812
|
+
persistent?: boolean | undefined;
|
|
2813
|
+
interval?: number | undefined;
|
|
2814
|
+
}
|
|
2773
2815
|
export function watchFile(
|
|
2774
2816
|
filename: PathLike,
|
|
2775
2817
|
options:
|
|
2776
|
-
| {
|
|
2777
|
-
|
|
2778
|
-
|
|
2779
|
-
}
|
|
2818
|
+
| (WatchFileOptions & {
|
|
2819
|
+
bigint?: false | undefined;
|
|
2820
|
+
})
|
|
2780
2821
|
| undefined,
|
|
2781
2822
|
listener: (curr: Stats, prev: Stats) => void
|
|
2782
|
-
):
|
|
2823
|
+
): StatWatcher;
|
|
2824
|
+
export function watchFile(
|
|
2825
|
+
filename: PathLike,
|
|
2826
|
+
options:
|
|
2827
|
+
| (WatchFileOptions & {
|
|
2828
|
+
bigint: true;
|
|
2829
|
+
})
|
|
2830
|
+
| undefined,
|
|
2831
|
+
listener: (curr: BigIntStats, prev: BigIntStats) => void
|
|
2832
|
+
): StatWatcher;
|
|
2783
2833
|
/**
|
|
2784
2834
|
* Watch for changes on `filename`. The callback `listener` will be called each time the file is accessed.
|
|
2785
2835
|
* @param filename A path to a file or directory. If a URL is provided, it must use the `file:` protocol.
|
|
2786
2836
|
*/
|
|
2787
|
-
export function watchFile(filename: PathLike, listener: (curr: Stats, prev: Stats) => void):
|
|
2837
|
+
export function watchFile(filename: PathLike, listener: (curr: Stats, prev: Stats) => void): StatWatcher;
|
|
2788
2838
|
/**
|
|
2789
2839
|
* Stop watching for changes on `filename`. If `listener` is specified, only that
|
|
2790
2840
|
* particular listener is removed. Otherwise, _all_ listeners are removed,
|
|
@@ -2987,6 +3037,7 @@ declare module 'fs' {
|
|
|
2987
3037
|
* @deprecated Since v1.0.0 - Use {@link stat} or {@link access} instead.
|
|
2988
3038
|
*/
|
|
2989
3039
|
export function exists(path: PathLike, callback: (exists: boolean) => void): void;
|
|
3040
|
+
/** @deprecated */
|
|
2990
3041
|
export namespace exists {
|
|
2991
3042
|
/**
|
|
2992
3043
|
* @param path A path to a file or directory. If a URL is provided, it must use the `file:` protocol.
|
|
@@ -3347,7 +3398,7 @@ declare module 'fs' {
|
|
|
3347
3398
|
end?: number | undefined;
|
|
3348
3399
|
}
|
|
3349
3400
|
/**
|
|
3350
|
-
* Unlike the 16 kb default `highWaterMark` for a
|
|
3401
|
+
* Unlike the 16 kb default `highWaterMark` for a `stream.Readable`, the stream
|
|
3351
3402
|
* returned by this method has a default `highWaterMark` of 64 kb.
|
|
3352
3403
|
*
|
|
3353
3404
|
* `options` can include `start` and `end` values to read a range of bytes from
|
|
@@ -3367,10 +3418,11 @@ declare module 'fs' {
|
|
|
3367
3418
|
* closing naturally.
|
|
3368
3419
|
*
|
|
3369
3420
|
* By default, the stream will emit a `'close'` event after it has been
|
|
3370
|
-
* destroyed
|
|
3421
|
+
* destroyed. Set the `emitClose` option to `false` to change this behavior.
|
|
3371
3422
|
*
|
|
3372
3423
|
* By providing the `fs` option, it is possible to override the corresponding `fs`implementations for `open`, `read`, and `close`. When providing the `fs` option,
|
|
3373
|
-
*
|
|
3424
|
+
* an override for `read` is required. If no `fd` is provided, an override for`open` is also required. If `autoClose` is `true`, an override for `close` is
|
|
3425
|
+
* also required.
|
|
3374
3426
|
*
|
|
3375
3427
|
* ```js
|
|
3376
3428
|
* import { createReadStream } from 'fs';
|
|
@@ -3408,7 +3460,6 @@ declare module 'fs' {
|
|
|
3408
3460
|
*
|
|
3409
3461
|
* If `options` is a string, then it specifies the encoding.
|
|
3410
3462
|
* @since v0.1.31
|
|
3411
|
-
* @return See `Readable Stream`.
|
|
3412
3463
|
*/
|
|
3413
3464
|
export function createReadStream(path: PathLike, options?: BufferEncoding | ReadStreamOptions): ReadStream;
|
|
3414
3465
|
/**
|
|
@@ -3424,11 +3475,12 @@ declare module 'fs' {
|
|
|
3424
3475
|
* file descriptor leak.
|
|
3425
3476
|
*
|
|
3426
3477
|
* By default, the stream will emit a `'close'` event after it has been
|
|
3427
|
-
* destroyed
|
|
3478
|
+
* destroyed. Set the `emitClose` option to `false` to change this behavior.
|
|
3428
3479
|
*
|
|
3429
3480
|
* By providing the `fs` option it is possible to override the corresponding `fs`implementations for `open`, `write`, `writev` and `close`. Overriding `write()`without `writev()` can reduce
|
|
3430
3481
|
* performance as some optimizations (`_writev()`)
|
|
3431
|
-
* will be disabled. When providing the `fs` option,
|
|
3482
|
+
* will be disabled. When providing the `fs` option, overrides for at least one of`write` and `writev` are required. If no `fd` option is supplied, an override
|
|
3483
|
+
* for `open` is also required. If `autoClose` is `true`, an override for `close`is also required.
|
|
3432
3484
|
*
|
|
3433
3485
|
* Like `fs.ReadStream`, if `fd` is specified, `fs.WriteStream` will ignore the`path` argument and will use the specified file descriptor. This means that no`'open'` event will be
|
|
3434
3486
|
* emitted. `fd` should be blocking; non-blocking `fd`s
|
|
@@ -3436,7 +3488,6 @@ declare module 'fs' {
|
|
|
3436
3488
|
*
|
|
3437
3489
|
* If `options` is a string, then it specifies the encoding.
|
|
3438
3490
|
* @since v0.1.31
|
|
3439
|
-
* @return See `Writable Stream`.
|
|
3440
3491
|
*/
|
|
3441
3492
|
export function createWriteStream(path: PathLike, options?: BufferEncoding | StreamOptions): WriteStream;
|
|
3442
3493
|
/**
|
|
@@ -3634,7 +3685,7 @@ declare module 'fs' {
|
|
|
3634
3685
|
* directory and subsequent read operations.
|
|
3635
3686
|
* @since v12.12.0
|
|
3636
3687
|
*/
|
|
3637
|
-
export function opendirSync(path:
|
|
3688
|
+
export function opendirSync(path: PathLike, options?: OpenDirOptions): Dir;
|
|
3638
3689
|
/**
|
|
3639
3690
|
* Asynchronously open a directory. See the POSIX [`opendir(3)`](http://man7.org/linux/man-pages/man3/opendir.3.html) documentation for
|
|
3640
3691
|
* more details.
|
|
@@ -3646,10 +3697,10 @@ declare module 'fs' {
|
|
|
3646
3697
|
* directory and subsequent read operations.
|
|
3647
3698
|
* @since v12.12.0
|
|
3648
3699
|
*/
|
|
3649
|
-
export function opendir(path:
|
|
3650
|
-
export function opendir(path:
|
|
3700
|
+
export function opendir(path: PathLike, cb: (err: NodeJS.ErrnoException | null, dir: Dir) => void): void;
|
|
3701
|
+
export function opendir(path: PathLike, options: OpenDirOptions, cb: (err: NodeJS.ErrnoException | null, dir: Dir) => void): void;
|
|
3651
3702
|
export namespace opendir {
|
|
3652
|
-
function __promisify__(path:
|
|
3703
|
+
function __promisify__(path: PathLike, options?: OpenDirOptions): Promise<Dir>;
|
|
3653
3704
|
}
|
|
3654
3705
|
export interface BigIntStats extends StatsBase<bigint> {
|
|
3655
3706
|
atimeNs: bigint;
|
|
@@ -3662,6 +3713,8 @@ declare module 'fs' {
|
|
|
3662
3713
|
}
|
|
3663
3714
|
export interface StatOptions {
|
|
3664
3715
|
bigint?: boolean | undefined;
|
|
3716
|
+
}
|
|
3717
|
+
export interface StatSyncOptions extends StatOptions {
|
|
3665
3718
|
throwIfNoEntry?: boolean | undefined;
|
|
3666
3719
|
}
|
|
3667
3720
|
export interface CopyOptions {
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
declare module 'http' {
|
|
43
43
|
import * as stream from 'node:stream';
|
|
44
44
|
import { URL } from 'node:url';
|
|
45
|
-
import { Socket, Server as NetServer } from 'node:net';
|
|
45
|
+
import { TcpSocketConnectOpts, Socket, Server as NetServer, LookupFunction } from 'node:net';
|
|
46
46
|
// incoming headers will never contain number
|
|
47
47
|
interface IncomingHttpHeaders extends NodeJS.Dict<string | string[]> {
|
|
48
48
|
accept?: string | undefined;
|
|
@@ -113,7 +113,7 @@ declare module 'http' {
|
|
|
113
113
|
type OutgoingHttpHeader = number | string | string[];
|
|
114
114
|
interface OutgoingHttpHeaders extends NodeJS.Dict<OutgoingHttpHeader> {}
|
|
115
115
|
interface ClientRequestArgs {
|
|
116
|
-
|
|
116
|
+
signal?: AbortSignal | undefined;
|
|
117
117
|
protocol?: string | null | undefined;
|
|
118
118
|
host?: string | null | undefined;
|
|
119
119
|
hostname?: string | null | undefined;
|
|
@@ -136,6 +136,7 @@ declare module 'http' {
|
|
|
136
136
|
setHost?: boolean | undefined;
|
|
137
137
|
// https://github.com/nodejs/node/blob/master/lib/_http_client.js#L278
|
|
138
138
|
createConnection?: ((options: ClientRequestArgs, oncreate: (err: Error, socket: Socket) => void) => Socket) | undefined;
|
|
139
|
+
lookup?: LookupFunction | undefined;
|
|
139
140
|
}
|
|
140
141
|
interface ServerOptions {
|
|
141
142
|
IncomingMessage?: typeof IncomingMessage | undefined;
|
|
@@ -183,6 +184,18 @@ declare module 'http' {
|
|
|
183
184
|
* @since v0.7.0
|
|
184
185
|
*/
|
|
185
186
|
maxHeadersCount: number | null;
|
|
187
|
+
/**
|
|
188
|
+
* The maximum number of requests socket can handle
|
|
189
|
+
* before closing keep alive connection.
|
|
190
|
+
*
|
|
191
|
+
* A value of `0` will disable the limit.
|
|
192
|
+
*
|
|
193
|
+
* When the limit is reached it will set the `Connection` header value to `close`,
|
|
194
|
+
* but will not actually close the connection, subsequent requests sent
|
|
195
|
+
* after the limit is reached will get `503 Service Unavailable` as a response.
|
|
196
|
+
* @since v16.10.0
|
|
197
|
+
*/
|
|
198
|
+
maxRequestsPerSocket: number | null;
|
|
186
199
|
/**
|
|
187
200
|
* The number of milliseconds of inactivity before a socket is presumed
|
|
188
201
|
* to have timed out.
|
|
@@ -341,11 +354,9 @@ declare module 'http' {
|
|
|
341
354
|
readonly socket: Socket | null;
|
|
342
355
|
constructor();
|
|
343
356
|
/**
|
|
344
|
-
* occurs, Same as binding to the `timeout` event.
|
|
345
|
-
*
|
|
346
357
|
* Once a socket is associated with the message and is connected,`socket.setTimeout()` will be called with `msecs` as the first parameter.
|
|
347
358
|
* @since v0.9.12
|
|
348
|
-
* @param callback Optional function to be called when a timeout
|
|
359
|
+
* @param callback Optional function to be called when a timeout occurs. Same as binding to the `timeout` event.
|
|
349
360
|
*/
|
|
350
361
|
setTimeout(msecs: number, callback?: () => void): this;
|
|
351
362
|
/**
|
|
@@ -940,7 +951,7 @@ declare module 'http' {
|
|
|
940
951
|
*/
|
|
941
952
|
destroy(error?: Error): void;
|
|
942
953
|
}
|
|
943
|
-
interface AgentOptions {
|
|
954
|
+
interface AgentOptions extends Partial<TcpSocketConnectOpts> {
|
|
944
955
|
/**
|
|
945
956
|
* Keep sockets around in a pool to be used by other requests in the future. Default = false
|
|
946
957
|
*/
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// Type definitions for non-npm package Node.js 16.
|
|
1
|
+
// Type definitions for non-npm package Node.js 16.11
|
|
2
2
|
// Project: https://nodejs.org/
|
|
3
3
|
// Definitions by: Microsoft TypeScript <https://github.com/Microsoft>
|
|
4
4
|
// DefinitelyTyped <https://github.com/DefinitelyTyped>
|
|
@@ -21,6 +21,7 @@
|
|
|
21
21
|
// Nikita Galkin <https://github.com/galkin>
|
|
22
22
|
// Parambir Singh <https://github.com/parambirs>
|
|
23
23
|
// Sebastian Silbermann <https://github.com/eps1lon>
|
|
24
|
+
// Seth Westphal <https://github.com/westy92>
|
|
24
25
|
// Simon Schick <https://github.com/SimonSchick>
|
|
25
26
|
// Thomas den Hollander <https://github.com/ThomasdenH>
|
|
26
27
|
// Wilco Bakker <https://github.com/WilcoBakker>
|
|
@@ -30,14 +31,12 @@
|
|
|
30
31
|
// Thanik Bhongbhibhat <https://github.com/bhongy>
|
|
31
32
|
// Marcin Kopacz <https://github.com/chyzwar>
|
|
32
33
|
// Trivikram Kamat <https://github.com/trivikr>
|
|
33
|
-
// Minh Son Nguyen <https://github.com/nguymin4>
|
|
34
34
|
// Junxiao Shi <https://github.com/yoursunny>
|
|
35
35
|
// Ilia Baryshnikov <https://github.com/qwelias>
|
|
36
36
|
// ExE Boss <https://github.com/ExE-Boss>
|
|
37
37
|
// Surasak Chaisurin <https://github.com/Ryan-Willpower>
|
|
38
38
|
// Piotr Błażejewicz <https://github.com/peterblazejewicz>
|
|
39
39
|
// Anna Henningsen <https://github.com/addaleax>
|
|
40
|
-
// Jason Kwok <https://github.com/JasonHK>
|
|
41
40
|
// Victor Perin <https://github.com/victorperin>
|
|
42
41
|
// Yongsheng Zhang <https://github.com/ZYSzys>
|
|
43
42
|
// NodeJS Contributors <https://github.com/NodeJS>
|
|
@@ -1778,6 +1778,13 @@ declare module 'inspector' {
|
|
|
1778
1778
|
* @since v8.0.0
|
|
1779
1779
|
*/
|
|
1780
1780
|
connect(): void;
|
|
1781
|
+
/**
|
|
1782
|
+
* Connects a session to the main thread inspector back-end.
|
|
1783
|
+
* An exception will be thrown if this API was not called on a Worker
|
|
1784
|
+
* thread.
|
|
1785
|
+
* @since 12.11.0
|
|
1786
|
+
*/
|
|
1787
|
+
connectToMainThread(): void;
|
|
1781
1788
|
/**
|
|
1782
1789
|
* Immediately close the session. All pending message callbacks will be called
|
|
1783
1790
|
* with an error. `session.connect()` will need to be called to be able to send
|
|
@@ -255,12 +255,12 @@ declare module 'net' {
|
|
|
255
255
|
* connects on `'192.168.1.1'`, the value of `socket.localAddress` would be`'192.168.1.1'`.
|
|
256
256
|
* @since v0.9.6
|
|
257
257
|
*/
|
|
258
|
-
readonly localAddress
|
|
258
|
+
readonly localAddress?: string;
|
|
259
259
|
/**
|
|
260
260
|
* The numeric representation of the local port. For example, `80` or `21`.
|
|
261
261
|
* @since v0.9.6
|
|
262
262
|
*/
|
|
263
|
-
readonly localPort
|
|
263
|
+
readonly localPort?: number;
|
|
264
264
|
/**
|
|
265
265
|
* The string representation of the remote IP address. For example,`'74.125.127.100'` or `'2001:4860:a005::68'`. Value may be `undefined` if
|
|
266
266
|
* the socket is destroyed (for example, if the client disconnected).
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@types/node",
|
|
3
|
-
"version": "16.
|
|
3
|
+
"version": "16.11.12",
|
|
4
4
|
"description": "TypeScript definitions for Node.js",
|
|
5
5
|
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
|
|
6
6
|
"license": "MIT",
|
|
@@ -110,6 +110,11 @@
|
|
|
110
110
|
"url": "https://github.com/eps1lon",
|
|
111
111
|
"githubUsername": "eps1lon"
|
|
112
112
|
},
|
|
113
|
+
{
|
|
114
|
+
"name": "Seth Westphal",
|
|
115
|
+
"url": "https://github.com/westy92",
|
|
116
|
+
"githubUsername": "westy92"
|
|
117
|
+
},
|
|
113
118
|
{
|
|
114
119
|
"name": "Simon Schick",
|
|
115
120
|
"url": "https://github.com/SimonSchick",
|
|
@@ -155,11 +160,6 @@
|
|
|
155
160
|
"url": "https://github.com/trivikr",
|
|
156
161
|
"githubUsername": "trivikr"
|
|
157
162
|
},
|
|
158
|
-
{
|
|
159
|
-
"name": "Minh Son Nguyen",
|
|
160
|
-
"url": "https://github.com/nguymin4",
|
|
161
|
-
"githubUsername": "nguymin4"
|
|
162
|
-
},
|
|
163
163
|
{
|
|
164
164
|
"name": "Junxiao Shi",
|
|
165
165
|
"url": "https://github.com/yoursunny",
|
|
@@ -190,11 +190,6 @@
|
|
|
190
190
|
"url": "https://github.com/addaleax",
|
|
191
191
|
"githubUsername": "addaleax"
|
|
192
192
|
},
|
|
193
|
-
{
|
|
194
|
-
"name": "Jason Kwok",
|
|
195
|
-
"url": "https://github.com/JasonHK",
|
|
196
|
-
"githubUsername": "JasonHK"
|
|
197
|
-
},
|
|
198
193
|
{
|
|
199
194
|
"name": "Victor Perin",
|
|
200
195
|
"url": "https://github.com/victorperin",
|
|
@@ -230,6 +225,6 @@
|
|
|
230
225
|
},
|
|
231
226
|
"scripts": {},
|
|
232
227
|
"dependencies": {},
|
|
233
|
-
"typesPublisherContentHash": "
|
|
234
|
-
"typeScriptVersion": "3.
|
|
228
|
+
"typesPublisherContentHash": "66478bcf856b451a83d797fa3c4495aeb7e18e217db90d6545b2711843bfe71c",
|
|
229
|
+
"typeScriptVersion": "3.8"
|
|
235
230
|
}
|
|
@@ -94,7 +94,11 @@ declare module 'process' {
|
|
|
94
94
|
type ExitListener = (code: number) => void;
|
|
95
95
|
type RejectionHandledListener = (promise: Promise<unknown>) => void;
|
|
96
96
|
type UncaughtExceptionListener = (error: Error, origin: UncaughtExceptionOrigin) => void;
|
|
97
|
-
|
|
97
|
+
/**
|
|
98
|
+
* Most of the time the unhandledRejection will be an Error, but this should not be relied upon
|
|
99
|
+
* as *anything* can be thrown/rejected, it is therefore unsafe to assume the the value is an Error.
|
|
100
|
+
*/
|
|
101
|
+
type UnhandledRejectionListener = (reason: unknown, promise: Promise<unknown>) => void;
|
|
98
102
|
type WarningListener = (warning: Error) => void;
|
|
99
103
|
type MessageListener = (message: unknown, sendHandle: unknown) => void;
|
|
100
104
|
type SignalsListener = (signal: Signals) => void;
|
|
@@ -236,6 +236,7 @@ declare module 'readline' {
|
|
|
236
236
|
* @since v0.1.98
|
|
237
237
|
*/
|
|
238
238
|
write(data: string | Buffer, key?: Key): void;
|
|
239
|
+
write(data: undefined | null | string | Buffer, key: Key): void;
|
|
239
240
|
/**
|
|
240
241
|
* Returns the real position of the cursor in relation to the input
|
|
241
242
|
* prompt + string. Long input (wrapping) strings, as well as multiple
|