Skip to content

Commit 6dca56b

Browse files
committed
Match the update's summary and description with its title
1 parent b73a008 commit 6dca56b

2 files changed

Lines changed: 13 additions & 2 deletions

File tree

usr/lib/linuxmint/mintUpdate/Classes.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ def __init__(self, package=None, source_name=None):
173173
if package.candidate.section == "kernel" or self.package_name.startswith("linux-headers") or self.real_source_name in ["linux", "linux-kernel", "linux-signed", "linux-meta"]:
174174
self.type = "kernel"
175175

176-
def add_package(self, pkg):
176+
def add_package(self, pkg, source_pkg = None):
177177
if self.main_package_name in SOURCE_PACKAGE_NAME_OVERRIDES:
178178
self.display_name = self.source_name
179179

@@ -185,6 +185,12 @@ def add_package(self, pkg):
185185
return
186186

187187
if self.main_package_name != self.source_name:
188+
# Use source package's information if exists
189+
if (source_pkg is not None
190+
and self.type != "kernel"
191+
and pkg.name not in SOURCE_PACKAGE_NAME_OVERRIDES):
192+
self.overwrite_main_package(source_pkg)
193+
return
188194
# Overwrite dev, dbg, common, arch packages
189195
for suffix in ["-dev", "-dbg", "-common", "-core", "-data", "-doc", ":i386", ":amd64"]:
190196
if (self.main_package_name.endswith(suffix) and not pkg.name.endswith(suffix)):

usr/lib/linuxmint/mintUpdate/aptUpdater.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -406,7 +406,12 @@ def add_update(self, package, kernel_update=False, test_version=None):
406406
if source_name in PRIORITY_UPDATES or not self.priority_updates_available:
407407
if source_name in self.updates:
408408
update = self.updates[source_name]
409-
update.add_package(package)
409+
410+
source_package = None
411+
if update.main_package_name != source_name:
412+
source_package = self.cache.get(source_name)
413+
414+
update.add_package(package, source_package)
410415
# Adjust update.old_version for kernel updates to try and
411416
# match the kernel, not the meta
412417
if kernel_update and package.is_installed and \

0 commit comments

Comments
 (0)