I cannot use tar -tz
as the solaris version I'm using does not accept the -z option.
I tried something like gunzip file.tar.gz | tar -tv
but that only gives:
tar: /dev/rmt/0: No such file or directory
…and unzips the tar.gz to .tar which is undesired. I only want to look inside them without modification.
Best Answer
Don't have a Solaris box handy, but wouldn't something like
zcat file.tar.gz | tar -tv
do the trick? That might need to begzcat
orgunzip -c
on Solaris, I'm not sure.UPDATE: @Riccardo Murri points out that the default behavior of
tar
on Solaris is NOT to read fromstdin
(which seems very un-Unixish, but ce la vie), sozcat file.tar.gz | tar -tv -f -
is probably what you need.UPDATE 2: Finally found what looks to be a decent site for Solaris
man
pages, so I present to youman gunzip
andman tar
.