[gnome-software/wip/kalev/local-bundles: 2/2] flatpak: Fix locally installed flatpak bundles to show up
- From: Kalev Lember <klember src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software/wip/kalev/local-bundles: 2/2] flatpak: Fix locally installed flatpak bundles to show up
- Date: Tue, 16 Oct 2018 11:18:22 +0000 (UTC)
commit f8f6bfca6d3225a2fdb76af70179192832fd8f2c
Author: Kalev Lember <klember redhat com>
Date: Tue Oct 16 13:08:52 2018 +0200
flatpak: Fix locally installed flatpak bundles to show up
The AsApps that were created for locally installed bundles didn't have
any way to map them back to flatpak refs. This commit adds AsBundle info
to fix this.
plugins/flatpak/gs-flatpak.c | 9 +++++++++
1 file changed, 9 insertions(+)
---
diff --git a/plugins/flatpak/gs-flatpak.c b/plugins/flatpak/gs-flatpak.c
index 3e476981..d4411e97 100644
--- a/plugins/flatpak/gs-flatpak.c
+++ b/plugins/flatpak/gs-flatpak.c
@@ -419,6 +419,15 @@ gs_flatpak_rescan_installed (GsFlatpak *self,
continue;
}
+ /* add the bundle info */
+ if (as_app_get_bundle_default (app) == NULL) {
+ g_autoptr(AsBundle) bundle = as_bundle_new ();
+ g_autofree gchar *ref = flatpak_ref_format_ref (FLATPAK_REF (app_ref));
+ as_bundle_set_kind (bundle, AS_BUNDLE_KIND_FLATPAK);
+ as_bundle_set_id (bundle, ref);
+ as_app_add_bundle (app, bundle);
+ }
+
as_app_set_branch (app, flatpak_ref_get_branch (FLATPAK_REF (app_ref)));
as_app_set_icon_path (app, path_exports);
as_app_add_keyword (app, NULL, "flatpak");
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]