archlinux-pkgbuilds/PKGBUILD

53 lines
1.7 KiB
Text
Raw Normal View History

2014-02-17 13:40:23 +01:00
# Maintainer: Philipp Schmitt (philipp<at>schmitt<dot>co)
pkgname=wallabag
2019-05-16 08:28:10 +02:00
pkgver=2.3.8
2016-06-07 13:21:07 +02:00
pkgrel=1
2014-02-17 13:40:23 +01:00
pkgdesc='Self hostable application for saving web pages'
arch=('any')
2014-02-17 13:40:23 +01:00
url='http://www.wallabag.org/'
2014-12-17 19:46:24 +01:00
license=('MIT')
depends=(
2018-01-20 13:48:54 +01:00
'php>=5.6'
'php-gd'
'php-tidy'
'pcre'
)
optdepends=(
'php-pgsql: For postgres storage'
'php-sqlite: For sqlite storage'
'rabbitmq: For async import'
'redis: For async import'
)
2014-02-17 13:40:23 +01:00
install="$pkgname.install"
options=(!strip)
2017-01-24 17:07:03 +01:00
source=("https://static.wallabag.org/releases/wallabag-release-${pkgver}.tar.gz")
2019-05-16 08:28:10 +02:00
sha256sums=('58f319ee41828fcc4fd00a14c4ac7c16b2179a47af21e257a15938311d1426eb')
backup=("etc/webapps/${pkgname}/parameters.yml"
"usr/share/webapps/${pkgname}/parameters.yml"
"var/lib/${pkgname}/data/db/wallabag.sqlite"
"usr/share/webapps/${pkgname}/data/db/wallabag.sqlite")
2014-02-17 13:40:23 +01:00
package() {
cd "${pkgdir}"
mkdir -p usr/share/webapps
mv "${srcdir}/${pkgver}" "usr/share/webapps/${pkgname}"
WALLABAG_CONF_DIR="${pkgdir}/usr/share/webapps/${pkgname}/app/config"
install -d "${pkgdir}/etc/webapps/${pkgname}/"
mv "${WALLABAG_CONF_DIR}"/parameters.yml "${pkgdir}/etc/webapps/${pkgname}/"
chown -R http:http "${pkgdir}/etc/webapps/${pkgname}"
ln -s "/etc/webapps/${pkgname}/parameters.yml" "${WALLABAG_CONF_DIR}"/
_VAR_DIR="${pkgdir}/var/lib/${pkgname}/"
install -d "$_VAR_DIR"
mv "${pkgdir}/usr/share/webapps/${pkgname}/"{data,var} "$_VAR_DIR"
ln -s "/var/lib/${pkgname}/"{data,var} "${pkgdir}/usr/share/webapps/${pkgname}/"
chown -R http:http "$_VAR_DIR"
2017-01-30 13:47:54 +01:00
sed -i "${_VAR_DIR}/var/bootstrap.php.cache" -e "s@__DIR__.'/../@'/usr/share/webapps/${pkgname}/@"
chown -R http:http "${pkgdir}/usr/share/webapps/${pkgname}"
2014-02-17 13:40:23 +01:00
}