From 34db77462dc90fb5fe37097435d42b18341a59e6 Mon Sep 17 00:00:00 2001 From: Mattia Rizzolo Date: Tue, 20 Jan 2015 00:33:56 +0100 Subject: reproducible: move get_trailing_icon() from _html_notes to common --- bin/reproducible_common.py | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'bin/reproducible_common.py') diff --git a/bin/reproducible_common.py b/bin/reproducible_common.py index 7969d593..d26574ad 100755 --- a/bin/reproducible_common.py +++ b/bin/reproducible_common.py @@ -373,6 +373,22 @@ def get_bugs(): log.error('item: ' + str(bug)) return packages +def get_trailing_icon(package, bugs): + html = '' + if package in bugs: + for bug in bugs[package]: + html += '#' + elif bugs[package][bug]['patch']: + html += 'bug-patch" title="#' + str(bug) + ', with patch">+' + else: + html += '" title="#' + str(bug) + '">+' + if html: + print(html) + return html + + # init the databases connections conn_db = start_db_connection() # the local sqlite3 reproducible db conn_udd = start_udd_connection() -- cgit v1.2.3-54-g00ecf