Commit 65908f7c authored by Chris Lamb's avatar Chris Lamb

Add support for removing package name prefixes from bug lists when they match.

parent 83074c57
......@@ -58,6 +58,25 @@ function DebbugsEnhancementSuite(options) {
document.title = h1.text();
});
$.option('package_prefixes', function () {
var match = document.title.match(/ package (\S+)$/)
if (match == null) {
return;
}
var needle = match[1] + ": ";
$('div.shortbugstatus a[href^=bugreport]').each(function() {
var elem = $(this);
var haystack = $(this).text();
if (haystack.indexOf(needle) == 0) {
elem.text(haystack.substring(needle.length));
}
});
});
$.option('collapse_bug_headers', function () {
var wrapper = $('body > div.msgreceived p:contains("View this report as a")')
.css('margin-top', '8px')
......
......@@ -62,4 +62,11 @@ var DebbugsEnhancementSuiteOptions = [
, "image": false
, "default": true
}
, {
"name": "package_prefixes"
, "title": "Package name prefixes"
, "description": "Remove the package name prefixes (eg. \"name: new upstream release\" from bug titles in lists where they match the current package."
, "image": false
, "default": true
}
]
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment