[arch-commits] Commit in python-kajiki/repos (2 files)
Felix Yan
felixonmars at archlinux.org
Mon Nov 4 08:21:19 UTC 2019
Date: Monday, November 4, 2019 @ 08:21:17
Author: felixonmars
Revision: 523695
archrelease: copy trunk to community-staging-any
Added:
python-kajiki/repos/community-staging-any/
python-kajiki/repos/community-staging-any/PKGBUILD
(from rev 523694, python-kajiki/trunk/PKGBUILD)
----------+
PKGBUILD | 41 +++++++++++++++++++++++++++++++++++++++++
1 file changed, 41 insertions(+)
Copied: python-kajiki/repos/community-staging-any/PKGBUILD (from rev 523694, python-kajiki/trunk/PKGBUILD)
===================================================================
--- community-staging-any/PKGBUILD (rev 0)
+++ community-staging-any/PKGBUILD 2019-11-04 08:21:17 UTC (rev 523695)
@@ -0,0 +1,41 @@
+# Maintainer: Thore Bödecker <foxxx0 at archlinux.org>
+pkgbase='python-kajiki'
+_pkgbase="${pkgbase#python-}"
+pkgname=("python-${_pkgbase}" "python2-${_pkgbase}")
+pkgver=0.8.1
+pkgrel=2
+pkgdesc='Python XML-based template engine with Genshi-like syntax and Jinja-style blocks'
+arch=('any')
+url='https://github.com/nandoflorestan/kajiki'
+license=('LGPL')
+makedepends=('python-setuptools' 'python2-setuptools')
+checkdepends=('python-babel' 'python2-babel' 'python-nose' 'python2-nose' 'python-nine' 'python2-nine')
+source=("${_pkgbase}-${pkgver}.tar.gz::https://github.com/nandoflorestan/kajiki/archive/v${pkgver}.tar.gz")
+sha512sums=('016338f2f585b4af774f25925b111bc82654589f222a273eb7bd785e8ce6383bf847cec99ab0e7b8925a4b9b080a47fb202398f1abdb9089b645bdcfb78fbfeb')
+
+prepare(){
+ cp -r "${srcdir}/${_pkgbase}-${pkgver}" "${srcdir}/${_pkgbase}-${pkgver}-py2"
+
+ # fix python interpreter for python2 stuff
+ find "${srcdir}/${_pkgbase}-${pkgver}-py2" -type f -name '*.py' \
+ -exec sed -i 's|^#!/usr/bin/env python$|#!/usr/bin/env python2|1' {} +
+}
+
+check() {
+ cd "${srcdir}/${_pkgbase}-${pkgver}"
+ python ./setup.py test
+ cd "${srcdir}/${_pkgbase}-${pkgver}-py2"
+ python2 ./setup.py test
+}
+
+package_python-kajiki() {
+ depends=('python')
+ cd "${srcdir}/${_pkgbase}-${pkgver}"
+ python ./setup.py install --root="$pkgdir/" --optimize=1
+}
+
+package_python2-kajiki() {
+ depends=('python2')
+ cd "${srcdir}/${_pkgbase}-${pkgver}-py2"
+ python2 ./setup.py install --root="$pkgdir/" --optimize=1
+}
More information about the arch-commits
mailing list