entries in the dataset now store what build system

they use
This commit is contained in:
Karma Riuk
2025-03-17 15:04:33 +01:00
parent d7b3d62c0c
commit 69295801ac
3 changed files with 12 additions and 0 deletions

View File

@ -124,6 +124,10 @@ class BuildHandler(ABC):
def clean_repo(self) -> None:
self.container.exec_run(self.clean_cmd())
@abstractmethod
def get_type(self) -> str:
pass
@abstractmethod
def compile_cmd(self) -> str:
pass
@ -160,6 +164,9 @@ class MavenHandler(BuildHandler):
# -Dstyle.color=never: Disables ANSI colors.
# -Dartifact.download.skip=true: Prevents Maven from printing download logs (but still downloads dependencies when needed).
def get_type(self) -> str:
return "maven"
def compile_cmd(self) -> str:
return f"{self.base_cmd} clean compile"
@ -205,6 +212,9 @@ class GradleHandler(BuildHandler):
super().__init__(repo_path, build_file, updates)
self.base_cmd = "gradle --no-daemon --console=plain"
def get_type(self) -> str:
return "gradle"
def compile_cmd(self) -> str:
return f"{self.base_cmd} compileJava"