3 ms·
> which doesn't have an index, and therefore requires a full scan of the file in order to show a file list Well, not exactly _full_, unless you're talking comp
by chungy 3y ago
> which doesn't have an index, and therefore requires a full scan of the file in order to show a file list
Well, not exactly _full_, unless you're talking compressed files. You can be smart and skip ahead to read the next file's metadata by knowing the current file's size. GNU tar and FreeBSD tar already do this; getting a listing of millions of files for a hundreds-of-gigabytes tar is nearly instant this way.
Compressing the archive does throw a wrench into it. You'll have to decompress the whole thing in that case.