From 51dafc45e2562ef729235adf13dcbda6a7efe9f0 Mon Sep 17 00:00:00 2001 From: Michael Aaron Murphy Date: Mon, 18 Oct 2021 16:40:57 +0200 Subject: [PATCH] fix(launcher): Exclude GNOME Initial Setup --- plugins/src/desktop_entries/mod.rs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/plugins/src/desktop_entries/mod.rs b/plugins/src/desktop_entries/mod.rs index 31787df..7c28cc0 100644 --- a/plugins/src/desktop_entries/mod.rs +++ b/plugins/src/desktop_entries/mod.rs @@ -59,6 +59,9 @@ pub async fn main() { } } +/// Desktop entries to hard exclude. +const EXCLUSIONS: &[&str] = &["GNOME Shell", "Initial Setup"]; + struct App { entries: Vec, locale: Option, @@ -126,7 +129,10 @@ impl App { } // Avoid showing the GNOME Shell entry entirely - if entry.name(None).map_or(false, |v| v == "GNOME Shell") { + if entry + .name(None) + .map_or(false, |v| EXCLUSIONS.contains(&v.as_ref())) + { continue; }