i have noticed that tarfile doesn't have a w:xz option or something similar,is there any way to create a xz file?i have this code in python
dir=tkFileDialog.askdirectory(initialdir="/home/david")
if x.get()=="gz":
tar = tarfile.open(dir+".tar.gz", "w:gz")
tar
for i in range(lbox.size()):
tar.add(e1.get()+"/"+lbox.get(i),arcname=lbox.get(i))
tar.close()
if x.get()=="bz":
tar = tarfile.open(dir+".tar.gz", "w:bz2")
tar
for i in range(lbox.size()):
tar.add(e1.get()+"/"+lbox.get(i),arcname=lbox.get(i))
tar.close()
if x.get()=="xz":
tar = tarfile.open(dir+".tar.gz", "w:gz")
tar
for i in range(lbox.size()):
tar.add(e1.get()+"/"+lbox.get(i),arcname=lbox.get(i))
tar.close()