blob: 9a5581d4bc489ff92df35cd65efcd8e51598cdd2 (
plain)
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
|
# Maintainer: Darkfish Tech <arch at darkfish dot com dot au>
_appname=quota_warning
pkgname=nextcloud-app-quota-warning
pkgver=1.21.0
pkgrel=1
pkgdesc="Send notifications to users when they have reached 85, 90 and 95% of their quota."
arch=('any')
url="https://github.com/nextcloud/quota_warning"
license=('AGPL-3.0-or-later')
makedepends=('yq' 'rsync')
source=("${_appname}-${pkgver}.tar.gz::${url}/archive/v${pkgver}.tar.gz")
sha512sums=('3f5309973d5823f1bc8d2919ea3c3417f7626c17eee34a59d356bc48886227ed26203fd3e6072375678dcc3298cefe32675f201dda95f6e113668e2df866c1e0')
# BEGIN Boilerplate nextcloud version calculation adopted from other packages
_get_nextcloud_versions() {
_app_min_major_version="$(xq '.info.dependencies.nextcloud["@min-version"] | tonumber' "${_appname}/appinfo/info.xml")"
_app_max_major_version="$(xq '.info.dependencies.nextcloud["@max-version"] | tonumber | .+1 | floor' "${_appname}/appinfo/info.xml")"
#echo "Min: ${_app_min_major_version}; Max: ${_app_max_major_version}"
}
_nextcloud_app_package() {
_get_nextcloud_versions
depends=("nextcloud>=${_app_min_major_version:-0}" "nextcloud<${_app_max_major_version:-999}")
}
# END Boilerplate nextcloud app version clamping
prepare() {
mv "${srcdir}/${_appname}-${pkgver}" "${srcdir}/${_appname}"
}
build() {
cd "${srcdir}/${_appname}"
make -j1
}
package() {
_install_dir="usr/share/webapps/nextcloud/apps"
install -d "${pkgdir}/${_install_dir}"
tar -x --no-same-owner -C "${pkgdir}/${_install_dir}" \
-f "${srcdir}/${_appname}/build/artifacts/${_appname}.tar.gz"
_nextcloud_app_package
}
|