aboutsummarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorPedro Henrique2019-11-20 13:29:03 -0300
committerPedro Henrique2019-11-20 13:29:03 -0300
commitde3a3da4821ff242fa07f15e8e3802ae8612238b (patch)
tree24e1d170a8625b5e9d6255228904b3b0ad5c6ea8
parent60da257c89f4870fd7331f0a278e5347f440a3a7 (diff)
downloadaur-de3a3da4821ff242fa07f15e8e3802ae8612238b.tar.gz
Fix missing icons
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD8
-rw-r--r--overgrive.install40
3 files changed, 38 insertions, 12 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 59eb71d1f305..3a045edd8ddc 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = overgrive
pkgdesc = A complete Google Drive™ desktop client solution for Linux
pkgver = 3.3.3
- pkgrel = 0
+ pkgrel = 1
url = https://www.thefanclub.co.za/overgrive
install = overgrive.install
arch = x86_64
diff --git a/PKGBUILD b/PKGBUILD
index cedb4a7b7742..5406c82248fb 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,7 +1,7 @@
# Maintainer: Pedro Henrique <pedro00dk@gmail.com>
pkgname=overgrive
pkgver=3.3.3
-pkgrel=0
+pkgrel=1
pkgdesc='A complete Google Drive™ desktop client solution for Linux'
arch=('x86_64')
url='https://www.thefanclub.co.za/overgrive'
@@ -27,12 +27,14 @@ prepare() {
# script to execute through terminal
mkdir --parents ./usr/bin/
- echo -e '/opt/thefanclub/overgrive/venv/bin/python /opt/thefanclub/overgrive/__pycache__/overgrive.cpython-38.pyc' \
+ echo -e '#!/usr/bin/sh\n/opt/thefanclub/overgrive/venv/bin/python /opt/thefanclub/overgrive/overgrive' \
> ./usr/bin/overgrive
+ chmod +x ./usr/bin/overgrive
+
# update .desktop files
sed --in-place -- \
- 's+Exec=.*+Exec=sh /usr/bin/overgrive+g' \
+ 's+Exec=.*+Exec=/usr/bin/overgrive+g' \
./usr/share/applications/overgrive.desktop \
./opt/thefanclub/overgrive/overgrive-autostart.desktop
}
diff --git a/overgrive.install b/overgrive.install
index ef84865edd16..7bd14f619d1a 100644
--- a/overgrive.install
+++ b/overgrive.install
@@ -4,10 +4,25 @@ post_install() {
/opt/thefanclub/overgrive/venv/bin/pip install --upgrade google-api-python-client
gtk-update-icon-cache -q -t -f usr/share/icons/hicolor
+
+ # Recomplie Schemas for good measure
if [ -f /usr/bin/glib-compile-schemas ]
then
/usr/bin/glib-compile-schemas /usr/share/glib-2.0/schemas/
fi
+
+ if [ -d /opt/thefanclub/overgrive/__pycache__ ]
+ then
+ cp /opt/thefanclub/overgrive/__pycache__/$(ls /opt/thefanclub/overgrive/__pycache__ | grep $(python3 -V | cut -d' ' -f2 | cut -d'.' -f1-2 | sed 's/\.//g')) /opt/thefanclub/overgrive/overgrive
+ rm -R /opt/thefanclub/overgrive/__pycache__
+ fi
+
+ # Post Install Check if correctly installed and Python version present
+ if [ ! -f /opt/thefanclub/overgrive/overgrive ]
+ then
+ echo "[overGrive] Install failed. Could not find compatible Python3 version. Install a compatible Python3 version then re-install overGrive, or consider using the AppImage."
+ exit 1
+ fi
}
post_upgrade() {
@@ -39,16 +54,25 @@ pre_remove() {
fi
fi
- # if [ -f "$userHome/.config/autostart/overgrive-autostart.desktop" ]
- # then
- # rm "$userHome/.config/autostart/overgrive-autostart.desktop"
- # fi
+ if [ -f "$userHome/.config/autostart/overgrive-autostart.desktop" ]
+ then
+ rm "$userHome/.config/autostart/overgrive-autostart.desktop"
+ fi
- # if [ -f "$userHome/.config/autostart/overgrive.desktop" ]
- # then
- # rm "$userHome/.config/autostart/overgrive.desktop"
- # fi
+ if [ -f "$userHome/.config/autostart/overgrive.desktop" ]
+ then
+ rm "$userHome/.config/autostart/overgrive.desktop"
+ fi
+ if [ -d "/opt/thefanclub/overgrive/venv" ]
+ then
+ rm -r "/opt/thefanclub/overgrive/venv"
+ fi
+
+ if [ -f "/opt/thefanclub/overgrive/overgrive" ]
+ then
+ rm "/opt/thefanclub/overgrive/overgrive"
+ fi
}
post_remove() {