From 575ab5323e050f068254f7e1d606c54fbd11ab1a Mon Sep 17 00:00:00 2001 From: Anthony Perkins Date: Sun, 21 Nov 2021 23:11:59 +0000 Subject: [PATCH] Enable gnome-shell extensions if they are installed --- roles/home-gui/files/gnome-setup.sh | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/roles/home-gui/files/gnome-setup.sh b/roles/home-gui/files/gnome-setup.sh index 1d18fb7..321f7d6 100644 --- a/roles/home-gui/files/gnome-setup.sh +++ b/roles/home-gui/files/gnome-setup.sh @@ -47,6 +47,25 @@ set_gnome_terminal_preferences () { } set_gnome_terminal_preferences +set_gnome_extensions () { + gnomeextcmd=/usr/bin/gnome-extensions + if ! [ -x $gnomeextcmd ] + then + # gnome-extensions not installed. + return + fi + for ext in dash-to-dock@micxgx.gmail.com appindicatorsupport@rgcjonas.gmail.com + do + installed=$($gnomeextcmd list | grep $ext) + enabled=$($gnomeextcmd list --enabled | grep $ext) + if [ x$ext == x$installed ] && [ x$ext != x$enabled ] + then + $gnomeextcmd enable $ext + fi + done +} +set_gnome_extensions + set_dash_to_dock_preferences () { if gsettings list-keys org.gnome.shell.extensions.dash-to-dock 2>&1 >/dev/null; then # Reset all dash-to-dock settings.