Example
~> g++ -Wall -I ${PATH_TO_SRC}/cclindenb/src/core
tarfile.cpp
~> ./a.out
~> tar tvf archive.tar
-rw-r--r-- pierre/users 14 2010-08-03 20:50 myfiles/item1.txt
-rw-r--r-- pierre/users 14 2010-08-03 20:50 myfiles/item2.txt
-rw-r--r-- pierre/users 692 2010-08-03 20:50 myfiles/code.cpp
tar xvf archive.tar --to-stdout myfiles/item1.txt 2> /dev/null
Hello World 1
tarfile.cpp
~> ./a.out
~> tar tvf archive.tar
-rw-r--r-- pierre/users 14 2010-08-03 20:50 myfiles/item1.txt
-rw-r--r-- pierre/users 14 2010-08-03 20:50 myfiles/item2.txt
-rw-r--r-- pierre/users 692 2010-08-03 20:50 myfiles/code.cpp
tar xvf archive.tar --to-stdout myfiles/item1.txt 2> /dev/null
Hello World 1
That's it,
Pierre
Very good program
ReplyDeletePretty useful, thanks!
ReplyDeletePretty useful, thanks!
ReplyDeleteThank you so much. Saved my time....
ReplyDeleteThank you for posting your code!
ReplyDelete