From fb3832fcf446c5e1e52322e254a1d01f77967c77 Mon Sep 17 00:00:00 2001 From: Kuninori Morimoto Date: Thu, 25 Apr 2019 13:58:25 +0900 Subject: script/html: count correct BSP patch number for statistics Current statistics is counting line number, but then, result will be strange if 1 line had multi patches. This patch counts correct BSP patch number. Signed-off-by: Kuninori Morimoto --- scripts/html.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'scripts') diff --git a/scripts/html.py b/scripts/html.py index 0eeaf16..537ee52 100755 --- a/scripts/html.py +++ b/scripts/html.py @@ -562,6 +562,7 @@ class periject_html(base.base): cnt_up = 0 cnt_all = 0 cnt_done= 0 + tmp = 0 with html("body"): html("h1").print("BSP patch list") @@ -586,12 +587,13 @@ class periject_html(base.base): html("td").print(a.text(os.path.basename(file).replace(".yaml", ""))) with html("td"): - cnt_bsp += self.task_commit_bsp(bsp) + tmp = self.task_commit_bsp(bsp) + cnt_bsp += tmp with html("td"): up = self.task_commit_upstream(v) if (up): - cnt_up += up + cnt_up += tmp cnt_done += 1 html("p").print("bsp:{}/upstream:{} = {:.1f}%".format(cnt_bsp, cnt_up, cnt_up * 100 /cnt_bsp)) -- cgit v1.2.3