Exemplo n.º 1
0
 def pack(self, src, dest):
     files = DirectoryPacker()
     if self.include:
         files.pack(src, include=self.filters)
     elif self.exclude:
         files.pack(src, exclude=self.filters)
     open(dest, 'wb').write(str(files.generate()))
Exemplo n.º 2
0
 def pack(self, src, dest):
     files = DirectoryPacker()
     if self.include:
         files.pack(src, include = self.filters)
     elif self.exclude:
         files.pack(src, exclude = self.filters)
     open(dest, 'wb').write(str(files.generate()))
Exemplo n.º 3
0
 def unpack(self, src, dest, force):
     if not force and os.path.isdir(dest):
         return
     reader = ByteReader(open(src, 'rb'))
     files = DirectoryPacker(reader)
     files.unpack(dest)
Exemplo n.º 4
0
 def unpack(self, src, dest, force):
     if not force and os.path.isdir(dest):
         return
     reader = ByteReader(open(src, 'rb'))
     files = DirectoryPacker(reader)
     files.unpack(dest)