-
Notifications
You must be signed in to change notification settings - Fork 87
Expand file tree
/
Copy pathinstall.sh
More file actions
executable file
·31 lines (24 loc) · 945 Bytes
/
Copy pathinstall.sh
File metadata and controls
executable file
·31 lines (24 loc) · 945 Bytes
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
#!/bin/bash
cd -- "$(dirname -- "$(readlink -f -- "$0")")" || exit 1
if [ "$1" != "-y" ]; then
echo "This installation process is deprecated because it can pull in packages"
echo "which mess with your system Python install if you didn't manually"
echo "install the system version first."
echo ""
echo "Press Enter to continue or Ctrl+C to cancel..."
read -r _FOO
fi
if [ "$(id -u)" != 0 ]; then
echo "* Building without elevated privileges"
python3 setup.py build
echo "* Acquiring permissions to perform system-wide install"
exec sudo -H "$0" -y "$@"
fi
echo "* Attempting to remove old QuickTile installs"
pip2 uninstall quicktile -y
pip3 uninstall quicktile --break-system-packages -y
rm -f /usr/local/bin/quicktile{,.py}
echo "* Running setup.py install"
python3 setup.py install
echo "* Copying quicktile.desktop to /etc/xdg/autostart/"
sudo cp quicktile/quicktile.desktop /etc/xdg/autostart/