aboutsummarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--PKGBUILD22
-rw-r--r--overgrive.install27
2 files changed, 35 insertions, 14 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 827acf255aa7..0d2af5d03c6f 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,28 +1,32 @@
# Maintainer: Pedro Henrique <pedro00dk@gmail.com>
pkgname=overgrive
-pkgver=3.2.3
-pkgrel=2
+pkgver=3.3.0
+pkgrel=1
pkgdesc="A complete Google Driveā„¢ desktop client solution for Linux"
arch=('x86_64')
url="https://www.thefanclub.co.za/overgrive"
license=("unknown")
depends=(
- libnotify libappindicator-gtk3 python2 python2-pyinotify python2-gobject python2-virtualenv
+ # original overgrive dependencies
+ # libnotify python3 python-oauth2client python-pyinotify python-pip python-gobject libappindicator-gtk3
+ #
+ # I removed python-pip package not to have any global python package that isn't a system package
+ libnotify python3 python-oauth2client python-pyinotify python-gobject libappindicator-gtk3
)
provides=("overgrive")
conflicts=("overgrive")
install="overgrive.install"
changelog=
source=(
- "https://www.thefanclub.co.za/sites/default/files/public/overgrive/overgrive-3.2.3-0-any.pkg.tar.xz"
+ "https://www.thefanclub.co.za/sites/default/files/public/overgrive/overgrive-3.3.0-0-any.pkg.tar.xz"
)
-noextract=("overgrive-3.2.3-0-any.pkg.tar.xz")
-md5sums=("6d7cc554e39b6ea399ff88358a58eb78")
+noextract=("overgrive-3.3.0-0-any.pkg.tar.xz")
+md5sums=("6304942914a53af282f0ac27e285275b")
prepare() {
- tar --extract --file='./overgrive-3.2.3-0-any.pkg.tar.xz'
- rm -- './overgrive-3.2.3-0-any.pkg.tar.xz'
+ tar --extract --file='./overgrive-3.3.0-0-any.pkg.tar.xz'
+ rm -- './overgrive-3.3.0-0-any.pkg.tar.xz'
sed --in-place -- \
- 's+Exec=python2+Exec=/opt/thefanclub/overgrive/venv/bin/python2+g' \
+ 's+Exec=python3+Exec=/opt/thefanclub/overgrive/venv/bin/python3+g' \
'./usr/share/applications/overgrive.desktop'
}
package() {
diff --git a/overgrive.install b/overgrive.install
index eb6930ac58f2..4b54581c8fa4 100644
--- a/overgrive.install
+++ b/overgrive.install
@@ -1,15 +1,32 @@
post_install() {
- virtualenv2 --system-site-packages /opt/thefanclub/overgrive/venv
- /opt/thefanclub/overgrive/venv/bin/python2 -m pip install --upgrade google-api-python-client
- /opt/thefanclub/overgrive/venv/bin/python2 -m pip install --upgrade oauth2client
- sudo glib-compile-schemas /usr/share/glib-2.0/schemas
+ python3 -m venv --system-site-packages /opt/thefanclub/overgrive/venv
+
+ # Install Google API Client for Python3 (for the virtualenv)
+ /opt/thefanclub/overgrive/venv/bin/pip3 install --upgrade google-api-python-client
+
+ # 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
+
+ # Choose cpython interpreter for overgrive and copy correct compiled version and remove folder
+ 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__
+ chmod 0755 /opt/thefanclub/overgrive/overgrive
+ fi
}
+
post_upgrade() {
post_install
}
+
post_remove() {
sudo rm -rf /opt/thefanclub/overgrive/
- if [ -z "$(ls -A /opt/thefanclub/)" ]; then
+ if [ -z "$(ls -A /opt/thefanclub/)" ]
+ then
sudo rmdir /opt/thefanclub/
fi
} \ No newline at end of file