MCPcopy Create free account
hub / github.com/comaps/comaps / run

Method run

tools/python/data/borders/setup.py:30–43  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

28
29class BuildCmd(build, object):
30 def run(self):
31 log.info("Creating {}".format(TAR_LZMA_PATH))
32 tar_stream = BytesIO()
33 borders_path = os.path.join(DATA_PATH, "borders")
34 with chdir(borders_path):
35 with tarfile.open(fileobj=tar_stream, mode="w") as tar:
36 for f in os.listdir(borders_path):
37 tar.add(f)
38
39 tar_stream.seek(0)
40 with lzma.open(TAR_LZMA_PATH, mode="w") as f:
41 f.write(tar_stream.read())
42
43 super(BuildCmd, self).run()
44
45
46class CleanCmd(clean, object):

Callers 1

runMethod · 0.45

Calls 7

chdirFunction · 0.85
formatMethod · 0.80
openMethod · 0.80
joinMethod · 0.45
addMethod · 0.45
writeMethod · 0.45
readMethod · 0.45

Tested by

no test coverage detected