@vltpkg/tar/unpack
Functions
checkFs()
function checkFs(h, tarDir, target): h is { path: string }Defined in: unpack.ts:194
Parameters
h
path?
string
tarDir
undefined | string
target
string
Returns
h is { path: string }
unpack()
function unpack(tarData, target): Promise<void>Defined in: unpack.ts:231
Parameters
tarData
Buffer
target
string
Returns
Promise<void>
unpackFileSync()
function unpackFileSync(file, target, offset): voidDefined in: unpack.ts:256
Unpack a tarball straight from a file on disk, skipping offset
leading bytes. Used to extract from a cache entry in place, so the
tarball never lands in the registry client’s in-memory cache.
Parameters
file
string
target
string
offset
number = 0
Returns
void
unpackSync()
function unpackSync(tarData, target): voidDefined in: unpack.ts:246
Same as unpack, but blocking. Faster: the async writers pay a libuv round trip per file, which costs more than the IO itself.
Parameters
tarData
Buffer
target
string
Returns
void