summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xscripts/myhtml.py17
1 files changed, 10 insertions, 7 deletions
diff --git a/scripts/myhtml.py b/scripts/myhtml.py
index 114d5a4..39ea0e1 100755
--- a/scripts/myhtml.py
+++ b/scripts/myhtml.py
@@ -129,11 +129,14 @@ class periject_html(base.base):
def git_title(self, id):
return self.run("git -C {} log -1 {} --format=%s".format(self.git, id))
- def bsp_url(self, id):
- return "https://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas-bsp.git/commit/?id={}".format(id)
-
- def upstream_url(self, id):
- return "https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id={}".format(id)
+ def commit_url(self, id, type):
+ if (type == "bsp"):
+ return "https://git.kernel.org/pub/scm/linux/kernel/git/horms/renesas-bsp.git/commit/?id={}".format(id)
+ if (type == "torvalds"):
+ return "https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id={}".format(id)
+ if (type == "next"):
+ return "https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id={}".format(id)
+ return id;
#--------------------
# print_css
@@ -494,7 +497,7 @@ class periject_html(base.base):
with html("ul"):
for bsp in bsp_list:
cnt += 1
- html("li").print(html("a", {"href":self.bsp_url(bsp),
+ html("li").print(html("a", {"href":self.commit_url(bsp, "bsp"),
"target":"subbody"}).text(self.git_title(bsp)))
return cnt
@@ -510,7 +513,7 @@ class periject_html(base.base):
with html("tr"):
html("th").print(item)
- html("td").print(html("a", {"href":self.upstream_url(commit),
+ html("td").print(html("a", {"href":self.commit_url(commit, item),
"target":"subbody"}).text(self.git_title(commit)))
return 1