Pipelining tar create and tar extract the "Python" way...
ishwor.gurung at gmail.com
Fri Sep 25 18:33:04 CEST 2009
>> > tar cvf - SrcDir | (cd /dest ; tar xvf -)
Check this out Ray if you haven't done it already
The tarfile module makes it possible to __read__ and write tar
archives, including those using gzip or bz2 compression.
Try breaking it up the functionality.
That's how shell achieves this functionality as whole, why wouldn't
you apply same technique in Python :-)
Some modules that could help for your specific situations are tarfile and os.
Popen is one way(It's what your spec says) but you'd want to do purely
in Python. Aren't you curious? :-) It's late and TGIF! Need sleep.
More information about the Python-list