fix(tt_tool): allow hardening in git repos without a remote

This commit is contained in:
htfab
2026-08-06 17:09:13 +02:00
parent ff75e344cd
commit 8bca34afbe
+3
View File
@@ -290,7 +290,10 @@ class Project:
return top_verilog[0] return top_verilog[0]
def get_git_remote(self): def get_git_remote(self):
try:
return list(Repo(self.local_dir).remotes[0].urls)[0] return list(Repo(self.local_dir).remotes[0].urls)[0]
except IndexError:
return "N/A"
def get_git_commit_hash(self): def get_git_commit_hash(self):
return Repo(self.local_dir).commit().hexsha return Repo(self.local_dir).commit().hexsha