Downloads the archive once, whole, when its size is known and at most
max_bytes, and reads its file names and sizes from that copy (a tar has
no index that a partial download could read, see the top of this file).
The copy is kept for the session, so members taken from it later need no
further request.
Usage
.tar_peek(
url,
size = NULL,
max_bytes = .tar_peek_max_bytes,
cache = FALSE,
skip_on_api_limit = FALSE
)Arguments
- url
the download URL of a
.tarfile, or the path of one on disk (then read directly, without any request)- size
the archive's size in bytes, from the repository's listing. An archive whose size is unknown or over
max_bytesis not downloaded, andNULLis returned.- max_bytes
the largest archive that is downloaded to list it
- cache
if
TRUE, keep the listing on disk for later sessions (seezip_peek_cache_clear())- skip_on_api_limit
