[gnome-software/1754-improve-the-sources-dropdown] snap: Use GS_APP_QUIRK_BETA_SOURCE



commit 910611ad7948a5e2192f4d8d9cce70c800d83d13
Author: Milan Crha <mcrha redhat com>
Date:   Wed Aug 3 15:54:19 2022 +0200

    snap: Use GS_APP_QUIRK_BETA_SOURCE
    
    Set the quirk when the branch matches certain heuristic values.

 plugins/snap/gs-plugin-snap.c | 2 ++
 1 file changed, 2 insertions(+)
---
diff --git a/plugins/snap/gs-plugin-snap.c b/plugins/snap/gs-plugin-snap.c
index e6b1e3c6a..486c82809 100644
--- a/plugins/snap/gs-plugin-snap.c
+++ b/plugins/snap/gs-plugin-snap.c
@@ -434,6 +434,8 @@ snap_to_app (GsPluginSnap *self, SnapdSnap *snap, const gchar *branch)
                gs_app_add_quirk (app, GS_APP_QUIRK_NOT_LAUNCHABLE);
        if (gs_plugin_check_distro_id (GS_PLUGIN (self), "ubuntu"))
                gs_app_add_quirk (app, GS_APP_QUIRK_PROVENANCE);
+       if (branch != NULL && (g_str_has_suffix (branch, "/beta") || g_str_has_suffix (branch, "/edge")))
+               gs_app_add_quirk (app, GS_APP_QUIRK_BETA_SOURCE);
 
        return g_steal_pointer (&app);
 }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]