@@ -0,0 +1,1023 @@
+import os.path%0A%0A%0Aclass Path:%0A    def __init__(self, base, name, version, date):%0A        build_dir = os.path.join(base, name, version, date)%0A        self.name = name%0A        self.build_dir = build_dir.translate(str.maketrans(':', '_'))%0A        self.dest_dir = os.path.join(self.build_dir, '_dest')%0A%0A    @property%0A    def tar_file(self):%0A        return os.path.join(self.build_dir, self.name)%0A%0A    @property%0A    def result_file(self):%0A        dest_list = os.listdir(self.dest_dir)%0A        try:%0A            dest_filename = next(x for x in dest_list if x.endswith('pkg.tar.xz'))%0A        except StopIteration:  # not found%0A            raise FileNotFoundError%0A        return os.path.join(self.dest_dir, dest_filename)%0A%0A    @property%0A    def log_file(self):%0A        return os.path.join(self.dest_dir, 'build.log')%0A%0A    @property%0A    def script_file(self):%0A        return os.path.join(self.build_dir, '_build_script.sh')%0A%0A%0Adef get_path(base, build):%0A    return Path(base, build.package.name, build.version, build.date.isoformat())%0A

Add path helper