-
Notifications
You must be signed in to change notification settings - Fork 7
/
install-mate-gnome-online-accounts.sh
executable file
·32 lines (26 loc) · 1.32 KB
/
install-mate-gnome-online-accounts.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#!/bin/bash
# Installs and configures the GNOME Control Centre on Ubuntu Mate to
# give access to the Online Services module
#
# GPL v3 licensed
# Written 2017 Peter Feerick
if [ "$(id -u)" != "0" ]; then
echo "This script must be executed as root. Exiting" >&2
exit 1
fi
echo -en "GNOME Online Accounts installer\n\n"
echo -ne "Refreshing software update repositories ... "
apt-get update >/dev/null 2>&1
echo -ne "done!\n"
echo -ne "Installing GNOME Online Accounts and dependencies ... "
apt-get -f -y install gnome-control-center gnome-online-accounts >/dev/null 2>&1
echo -ne "done!\n"
echo -ne "Adding menu entry to Applications -> System Tools ... "
mkdir -p ~/.local/share/applications/
cp /usr/share/applications/gnome-control-center.desktop ~/.local/share/applications/
sed -i '/^OnlyShowIn/d' ~/.local/share/applications/gnome-control-center.desktop
sed -i 's/^Exec.*/Exec=env XDG_CURRENT_DESKTOP=GNOME gnome-control-center --overview/' ~/.local/share/applications/gnome-control-center.desktop
sed -i 's/^Name=Settings/Name=GNOME Control Center/' ~/.local/share/applications/gnome-control-center.desktop
echo -ne "done!\n"
echo -ne "\nYou can now launch the GNOME Control Center from Applications -> System Tools.\n"
echo -ne "This will give you access to all the settings modules, including Online Accounts.\n\n"