From 54f5bd29ec86aee45994611cee69c10c7ddb3972 Mon Sep 17 00:00:00 2001 From: Kuninori Morimoto Date: Tue, 23 Mar 2021 15:54:19 +0900 Subject: html_base: indicate commit itself if it does not exist MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sometimes we run "make" without update Linux, and then we can't find some commits. In such case git indicates error message, but periject will not stop, and we lose such tasks from HTML. Now we can use run2() which can get return value. By This patch, periject indicates commit itself as title. Signed-off-by: Kuninori Morimoto Reviewed-by: Niklas Söderlund --- scripts/html_base.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'scripts') diff --git a/scripts/html_base.py b/scripts/html_base.py index 562d90f..4941721 100644 --- a/scripts/html_base.py +++ b/scripts/html_base.py @@ -121,7 +121,11 @@ class myhtml(base.base): return os.path.relpath(file.replace("yaml", "html").replace("projects", "html"), frm) def git_title(self, id): - return self.run("git -C {} log -1 {} --format=%s".format(self.git, id)) + title, ret = self.run2("git -C {} log -1 {} --format=%s".format(self.git, id)) + if (ret != 0): + title = "commit {}".format(id) + + return title def commit_url(self, id, type): if (type == "bsp"): -- cgit v1.2.3