Skip to content

Commit

Permalink
GNOME: add noninteractive extension installation
Browse files Browse the repository at this point in the history
  • Loading branch information
jan-revay committed Dec 15, 2024
1 parent ed213a0 commit e1bcf4a
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 8 deletions.
21 changes: 14 additions & 7 deletions CommonInitScripts/gnome_install_extensions.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,21 @@ function install_gnome_extension
{
local EXTENSION_ID="$1"

# TODO test whether all extensions are installed the first call
# if not, call gdbus in a while loop
if ! gnome-extensions list | grep "${EXTENSION_ID}"; then
gdbus call --session --dest org.gnome.Shell.Extensions \
--object-path /org/gnome/Shell/Extensions \
--method org.gnome.Shell.Extensions.InstallRemoteExtension \
"${EXTENSION_ID}"
if [ "${NONINTERACTIVE}" == 'true' ]; then
gext --filesystem install "${EXTENSION_ID}"
else
gext install "${EXTENSION_ID}"
fi

#
# # TODO test whether all extensions are installed the first call
# # if not, call gdbus in a while loop
# if ! gnome-extensions list | grep "${EXTENSION_ID}"; then
# gdbus call --session --dest org.gnome.Shell.Extensions \
# --object-path /org/gnome/Shell/Extensions \
# --method org.gnome.Shell.Extensions.InstallRemoteExtension \
# "${EXTENSION_ID}"
# fi
}

echo "Warning - extensions temporary disabled (because of new GNOME version)"
Expand Down
2 changes: 1 addition & 1 deletion Ubuntu_22.04/interactive_part.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@
if [ "$1" == "--noninteractive" ]; then
readonly NONINTERACTIVE='true'
echo "Skipping interactive commands as $1 parameter was provided"
. ../CommonInitScripts/gnome_install_extensions.sh
elif [ "$1" == "" ]; then
# GNOME extensions
. ../CommonInitScripts/gnome_install_extensions.sh
# TODO configure postfix in advance from command line
# TODO what is this app and why does it automatically install itself on Ubuntu
# server/desktop, but not in wsl? It needs user interaction hence adding it here.
Expand Down

0 comments on commit e1bcf4a

Please sign in to comment.