Project

General

Profile

Actions

Bug #25233

open

Add update types for dpkg packages

Added by Alexis Mousset 4 months ago. Updated 15 days ago.

Status:
New
Priority:
N/A
Assignee:
-
Category:
Agent
Target version:
Severity:
UX impact:
User visibility:
Effort required:
Priority:
0
Name check:
To do
Fix check:
To do
Regression:
No

Description

From PackageKit:

        // the default update info
        state = PK_INFO_ENUM_NORMAL;

        // let find what kind of upgrade this is
        pkgCache::VerFileIterator vf = pkgInfo.ver.FileList();
        std::string origin  = vf.File().Origin() == NULL ? "" : vf.File().Origin();
        std::string archive = vf.File().Archive() == NULL ? "" : vf.File().Archive();
        std::string label   = vf.File().Label() == NULL ? "" : vf.File().Label();

        if (origin.compare("Backports.org archive") == 0 ||
            ends_with(origin, "-backports")) {
            state = PK_INFO_ENUM_ENHANCEMENT;
        } else if (ends_with(archive, "-security") ||
                   label.compare("Debian-Security") == 0) {
            state = PK_INFO_ENUM_SECURITY;
        } else if (ends_with(archive, "-backports")) {
            state = PK_INFO_ENUM_ENHANCEMENT;
        } else if (ends_with(archive, "-proposed-updates") || ends_with(archive, "-updates-proposed")) {
            state = PK_INFO_ENUM_LOW;
        } else if (ends_with(archive, "-updates")) {
            state = PK_INFO_ENUM_BUGFIX;
        }

Actions

Also available in: Atom PDF