@types/tar 6.1.8 → 6.1.10
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.
- tar/README.md +1 -1
- tar/index.d.ts +21 -20
- tar/package.json +2 -2
tar/README.md
CHANGED
|
@@ -8,7 +8,7 @@ This package contains type definitions for tar (https://github.com/npm/node-tar)
|
|
|
8
8
|
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/tar.
|
|
9
9
|
|
|
10
10
|
### Additional Details
|
|
11
|
-
* Last updated:
|
|
11
|
+
* Last updated: Mon, 20 Nov 2023 23:36:24 GMT
|
|
12
12
|
* Dependencies: [@types/node](https://npmjs.com/package/@types/node), [minipass](https://npmjs.com/package/minipass)
|
|
13
13
|
|
|
14
14
|
# Credits
|
tar/index.d.ts
CHANGED
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
import stream = require("stream");
|
|
4
4
|
import zlib = require("zlib");
|
|
5
5
|
import MiniPass = require("minipass");
|
|
6
|
+
import fs = require("fs");
|
|
6
7
|
|
|
7
8
|
// #region Interfaces
|
|
8
9
|
|
|
@@ -229,7 +230,7 @@ export interface PackOptions {
|
|
|
229
230
|
*
|
|
230
231
|
* @default process.cwd()
|
|
231
232
|
*/
|
|
232
|
-
cwd?: string
|
|
233
|
+
cwd?: string;
|
|
233
234
|
/**
|
|
234
235
|
* A path portion to prefix onto the entries in the archive.
|
|
235
236
|
*/
|
|
@@ -243,7 +244,7 @@ export interface PackOptions {
|
|
|
243
244
|
* A function that gets called with (path, stat) for each entry being added.
|
|
244
245
|
* Return true to add the entry to the archive, or false to omit it.
|
|
245
246
|
*/
|
|
246
|
-
filter?(path: string, stat:
|
|
247
|
+
filter?(path: string, stat: fs.Stats): boolean;
|
|
247
248
|
/**
|
|
248
249
|
* Omit metadata that is system-specific: ctime, atime, uid, gid, uname,
|
|
249
250
|
* gname, dev, ino, and nlink. Note that mtime is still included, because
|
|
@@ -425,7 +426,7 @@ export interface CreateOptions {
|
|
|
425
426
|
* A function that gets called with (path, stat) for each entry being
|
|
426
427
|
* added. Return true to add the entry to the archive, or false to omit it.
|
|
427
428
|
*/
|
|
428
|
-
filter?(path: string, stat:
|
|
429
|
+
filter?(path: string, stat: fs.Stats): boolean;
|
|
429
430
|
|
|
430
431
|
/**
|
|
431
432
|
* Omit metadata that is system-specific: ctime, atime, uid, gid, uname,
|
|
@@ -739,7 +740,7 @@ export interface ReplaceOptions {
|
|
|
739
740
|
* A function that gets called with (path, stat) for each entry being
|
|
740
741
|
* added. Return true to emit the entry from the archive, or false to skip it.
|
|
741
742
|
*/
|
|
742
|
-
filter?(path: string, stat:
|
|
743
|
+
filter?(path: string, stat: fs.Stats): boolean;
|
|
743
744
|
|
|
744
745
|
/**
|
|
745
746
|
* Allow absolute paths. By default, / is stripped from absolute paths.
|
|
@@ -814,7 +815,7 @@ export type RequiredFileOptions = {
|
|
|
814
815
|
*/
|
|
815
816
|
export function create(
|
|
816
817
|
options: CreateOptions,
|
|
817
|
-
fileList:
|
|
818
|
+
fileList: readonly string[],
|
|
818
819
|
callback?: (err?: Error) => void,
|
|
819
820
|
): stream.Readable;
|
|
820
821
|
|
|
@@ -824,11 +825,11 @@ export function create(
|
|
|
824
825
|
* fileList that starts with an @ symbol is a tar archive whose entries will
|
|
825
826
|
* be added. To add a file that starts with @, prepend it with `./`.
|
|
826
827
|
*/
|
|
827
|
-
export function create(options: CreateOptions & FileOptions, fileList:
|
|
828
|
-
export function create(options: CreateOptions & FileOptions & { sync: true }, fileList:
|
|
828
|
+
export function create(options: CreateOptions & FileOptions, fileList: readonly string[]): Promise<void>;
|
|
829
|
+
export function create(options: CreateOptions & FileOptions & { sync: true }, fileList: readonly string[]): void;
|
|
829
830
|
export function create(
|
|
830
831
|
options: CreateOptions & FileOptions,
|
|
831
|
-
fileList:
|
|
832
|
+
fileList: readonly string[],
|
|
832
833
|
callback: (err?: Error) => void,
|
|
833
834
|
): void;
|
|
834
835
|
|
|
@@ -851,7 +852,7 @@ export const c: typeof create;
|
|
|
851
852
|
*/
|
|
852
853
|
export function extract(
|
|
853
854
|
options: ExtractOptions,
|
|
854
|
-
fileList?:
|
|
855
|
+
fileList?: readonly string[],
|
|
855
856
|
callback?: (err?: Error) => void,
|
|
856
857
|
): stream.Writable;
|
|
857
858
|
|
|
@@ -865,11 +866,11 @@ export function extract(
|
|
|
865
866
|
* extraction errors will cause a warn event to be emitted. If the cwd is
|
|
866
867
|
* missing, or not a directory, then the extraction will fail completely.
|
|
867
868
|
*/
|
|
868
|
-
export function extract(options: ExtractOptions & FileOptions, fileList?:
|
|
869
|
-
export function extract(options: ExtractOptions & FileOptions & { sync: true }, fileList?:
|
|
869
|
+
export function extract(options: ExtractOptions & FileOptions, fileList?: readonly string[]): Promise<void>;
|
|
870
|
+
export function extract(options: ExtractOptions & FileOptions & { sync: true }, fileList?: readonly string[]): void;
|
|
870
871
|
export function extract(
|
|
871
872
|
options: ExtractOptions & FileOptions,
|
|
872
|
-
fileList:
|
|
873
|
+
fileList: readonly string[] | undefined,
|
|
873
874
|
callback: (err?: Error) => void,
|
|
874
875
|
): void;
|
|
875
876
|
|
|
@@ -884,14 +885,14 @@ export const x: typeof extract;
|
|
|
884
885
|
* are listed. If the archive is gzipped, then tar will detect this and unzip
|
|
885
886
|
* it.
|
|
886
887
|
*/
|
|
887
|
-
export function list(options: ListOptions & RequiredFileOptions, fileList?:
|
|
888
|
+
export function list(options: ListOptions & RequiredFileOptions, fileList?: readonly string[]): Promise<void>;
|
|
888
889
|
export function list(
|
|
889
890
|
options: ListOptions & RequiredFileOptions & { sync: true },
|
|
890
|
-
fileList?:
|
|
891
|
+
fileList?: readonly string[],
|
|
891
892
|
): void;
|
|
892
893
|
export function list(callback?: (err?: Error) => void): Parse;
|
|
893
|
-
export function list(optionsOrFileList: ListOptions |
|
|
894
|
-
export function list(options: ListOptions, fileList:
|
|
894
|
+
export function list(optionsOrFileList: ListOptions | readonly string[], callback?: (err?: Error) => void): Parse;
|
|
895
|
+
export function list(options: ListOptions, fileList: readonly string[], callback?: (err?: Error) => void): Parse;
|
|
895
896
|
|
|
896
897
|
/**
|
|
897
898
|
* Alias for list
|
|
@@ -906,10 +907,10 @@ export const t: typeof list;
|
|
|
906
907
|
* a tar archive whose entries will be added. To add a file that
|
|
907
908
|
* starts with @, prepend it with ./.
|
|
908
909
|
*/
|
|
909
|
-
export function replace(options: ReplaceOptions, fileList?:
|
|
910
|
+
export function replace(options: ReplaceOptions, fileList?: readonly string[]): Promise<void>;
|
|
910
911
|
export function replace(
|
|
911
912
|
options: ReplaceOptions,
|
|
912
|
-
fileList:
|
|
913
|
+
fileList: readonly string[] | undefined,
|
|
913
914
|
callback: (err?: Error) => void,
|
|
914
915
|
): Promise<void>;
|
|
915
916
|
|
|
@@ -925,10 +926,10 @@ export const r: typeof replace;
|
|
|
925
926
|
* that starts with an @ symbol is a tar archive whose entries will be added.
|
|
926
927
|
* To add a file that starts with @, prepend it with ./.
|
|
927
928
|
*/
|
|
928
|
-
export function update(options: ReplaceOptions, fileList?:
|
|
929
|
+
export function update(options: ReplaceOptions, fileList?: readonly string[]): Promise<void>;
|
|
929
930
|
export function update(
|
|
930
931
|
options: ReplaceOptions,
|
|
931
|
-
fileList:
|
|
932
|
+
fileList: readonly string[] | undefined,
|
|
932
933
|
callback: (err?: Error) => void,
|
|
933
934
|
): Promise<void>;
|
|
934
935
|
|
tar/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@types/tar",
|
|
3
|
-
"version": "6.1.
|
|
3
|
+
"version": "6.1.10",
|
|
4
4
|
"description": "TypeScript definitions for tar",
|
|
5
5
|
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/tar",
|
|
6
6
|
"license": "MIT",
|
|
@@ -28,6 +28,6 @@
|
|
|
28
28
|
"@types/node": "*",
|
|
29
29
|
"minipass": "^4.0.0"
|
|
30
30
|
},
|
|
31
|
-
"typesPublisherContentHash": "
|
|
31
|
+
"typesPublisherContentHash": "31f025dae81a85ec265ef7c9defb7ba06b3692ae5dc402cf34f734a7946c5850",
|
|
32
32
|
"typeScriptVersion": "4.5"
|
|
33
33
|
}
|