here's a small script I wrote and use
note the line
arcname = os.path.splitdrive(p)[-1].lstrip(os.sep)
if I comment out `.lstrip(os.sep)`, I get a zip file like rzed
describes
###
import sys
import zipfile
import time
import os
if __name__ == '__main__':
pths = sy
rzed wrote:
> I create a zip file on my WinXP system, using this function:
>
>
> import zipfile
> import os
> import os.path
>
> def zipdir(dirname, zfname):
> zf = zipfile.ZipFile(zfname, 'w', zipfile.ZIP_DEFLATED)
> for root, dirs, files in os.walk(dirname):
> for f in files:
>
rzed wrote:
> I create a zip file on my WinXP system, using this function:
> ...
> However, WinXP has a "feature" (if that's what it is): if you click
> on a zip file in explorer, an explorer window opens that shows the
> contents of the zip file. If I use WinZip or UltimateZip to create
> the
I create a zip file on my WinXP system, using this function:
import zipfile
import os
import os.path
def zipdir(dirname, zfname):
zf = zipfile.ZipFile(zfname, 'w', zipfile.ZIP_DEFLATED)
for root, dirs, files in os.walk(dirname):
for f in files:
fullname = os.path.join