Fixed for repo path

This commit is contained in:
Dimitris Zlatanidis 2023-05-07 20:19:53 +03:00
parent b23f7606ab
commit 82784ce92b

View file

@ -32,6 +32,7 @@ class Slackbuilds(Configs):
def __init__(self, repository: str, data: dict, slackbuilds: list, flags: list, mode: str):
super(Configs, self).__init__()
self.repository: str = repository
self.data = data
self.slackbuilds: list = slackbuilds
self.flags: list = flags
@ -175,12 +176,8 @@ class Slackbuilds(Configs):
slackbuild = Path(self.build_path, sbo, f'{sbo}.SlackBuild')
# Copy slackbuilds to the build folder.
if self.repos.ponce_repo:
path_ponce_repo_package = Path(self.repos.ponce_repo_path, location, sbo)
shutil.copytree(path_ponce_repo_package, build_path)
else:
path_sbo_repo_package = Path(self.repos.sbo_repo_path, location, sbo)
shutil.copytree(path_sbo_repo_package, build_path)
path_repo_package = Path(self.repos.repositories[self.repository][1], location, sbo)
shutil.copytree(path_repo_package, build_path)
os.chmod(slackbuild, 0o775)