def handle_vol(self, vol): n = len(self.opts) if n == 0: print "Usage: unpack <out_path>" return 1 else: out_path = self.opts[0] img = Imager() img.unpack(vol, out_path) if self.args.verbose: print "Unpacked %d bytes" % (img.get_total_bytes()) return 0
def handle_vol(self, vol): n = len(self.opts) if n == 0: print("Usage: unpack <out_path>") return 1 else: out_path = self.opts[0] img = Imager() img.unpack(vol, out_path) if self.args.verbose: print("Unpacked %d bytes" % (img.get_total_bytes())) return 0
def handle_vol(self, vol): n = len(self.opts) if n == 0: print("Usage: unpack <out_path> [fsuae]") return 1 else: meta_mode = Imager.META_MODE_DB if 'fsuae' in self.opts: meta_mode = Imager.META_MODE_FSUAE out_path = self.opts[0] img = Imager(meta_mode=meta_mode) img.unpack(vol, out_path) if self.args.verbose: print("Unpacked %d bytes" % (img.get_total_bytes())) return 0