Re: deleting from tarfile

2005-01-16 Thread "Martin v. Löwis"
Mark McEahern wrote: It doesn't appear so. A workaround, of course, is to create a new file with the subset of files from the old file: That is actually the *only* way to do that. tarfiles cannot be "sparse", in the sense that parts of the file can be marked as deleted. So in order to delete a fi

Re: deleting from tarfile

2005-01-15 Thread Michael Hoffman
Uwe Mayer wrote: is it possible to delete a file from a tar-archive using the tarfile module? The tarlib.py in pyNMS claims to be able to do it. It doesn't use the tarfile module, though. http://cvs.sourceforge.net/viewcvs.py/pynms/pyNMS/lib/tarlib.py?rev=1.1.1.1&view=auto -- Michael Hoffman -- htt

Re: deleting from tarfile

2005-01-15 Thread Mark McEahern
Uwe Mayer wrote: Hi, is it possible to delete a file from a tar-archive using the tarfile module? Thanks Uwe It doesn't appear so. A workaround, of course, is to create a new file with the subset of files from the old file: #!/usr/bin/env python import tarfile import os def removeFile(filena

deleting from tarfile

2005-01-15 Thread Uwe Mayer
Hi, is it possible to delete a file from a tar-archive using the tarfile module? Thanks Uwe -- http://mail.python.org/mailman/listinfo/python-list