Welcome, guest! Login / Register - Why register?
Psst.. new poll here.
[email protected] web/email now available. Want one? Go here.
Cannot use outlook/hotmail/live here to register as they blocking our mail servers. #microsoftdeez
Obey the Epel!

Paste

Pasted as Python by musashi ( 14 years ago )
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import time
import tarfile
import progressbar
import ConfigParser

#config
config = ConfigParser.ConfigParser()
config.read('config.conf')
infile = config.get('in','infile')
outfile= config.get('out','outfile')

#tar, progressbar

tar = tarfile.open(outfile,"w|gz")
tar.add(infile)
tar.close()

bar = progressbar.ProgressBar(widgets=['Архивация файла: ',
                  progressbar.Bar(left='[', marker='=', right='] '),
                  progressbar.Percentage()]).start()

tar = tarfile.open(outfile,"w|gz")
tar.add(infile)
tar.close()

bar.finish()

 

Revise this Paste

Your Name: Code Language: