Commit b7ed897e authored by Timothée Ravier's avatar Timothée Ravier
Browse files

PackageKit: Never run on rpm-ostree managed systems

This backend should not be installed on rpm-ostree based systems but if
it is, don't start it. This is useful during development as there is
currently no option to not build the PackageKit backend.
parent 11616cbc
......@@ -10,6 +10,7 @@
#include "PackageKitResource.h"
#include <AppStreamQt/pool.h>
#include <PackageKit/Transaction>
#include <QFile>
#include <QPointer>
#include <QSet>
#include <QSharedPointer>
......@@ -46,7 +47,7 @@ public:
Transaction *removeApplication(AbstractResource *app) override;
bool isValid() const override
{
return true;
return !QFile::exists(QStringLiteral("/run/ostree-booted"));
}
QSet<AbstractResource *> upgradeablePackages() const;
bool isFetching() const override;
......
Supports Markdown
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