[arch-commits] Commit in (4 files)

Felix Yan felixonmars at archlinux.org
Tue Dec 27 08:21:34 UTC 2016


    Date: Tuesday, December 27, 2016 @ 08:21:33
  Author: felixonmars
Revision: 203021

addpkg: python-prawcore 0.6.0-1

Added:
  python-prawcore/
  python-prawcore/repos/
  python-prawcore/trunk/
  python-prawcore/trunk/PKGBUILD

----------+
 PKGBUILD |   46 ++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 46 insertions(+)

Added: python-prawcore/trunk/PKGBUILD
===================================================================
--- python-prawcore/trunk/PKGBUILD	                        (rev 0)
+++ python-prawcore/trunk/PKGBUILD	2016-12-27 08:21:33 UTC (rev 203021)
@@ -0,0 +1,46 @@
+# $Id$
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+pkgbase=python-prawcore
+pkgname=('python-prawcore' 'python2-prawcore')
+pkgver=0.6.0
+pkgrel=1
+pkgdesc="Low-level communication layer for PRAW 4+."
+arch=('any')
+license=('BSD')
+url="https://github.com/praw-dev/prawcore"
+makedepends=('python-setuptools' 'python2-setuptools' 'python-requests' 'python2-requests' 'git')
+checkdepends=('python-mock' 'python2-mock' 'python-betamax-matchers' 'python2-betamax-matchers'
+              'python-betamax-serializers' 'python2-betamax-serializers')
+source=("git+https://github.com/praw-dev/prawcore.git#tag=v$pkgver")
+md5sums=('SKIP')
+
+prepare() {
+  sed -i 's/mock ==1.0.1/mock/' prawcore/setup.py
+  cp -a prawcore{,-py2}
+}
+
+check() {
+  # https://github.com/praw-dev/prawcore/issues/53
+  cd "$srcdir"/prawcore
+  python setup.py test || warning "Tests failed"
+
+  cd "$srcdir"/prawcore-py2
+  python2 setup.py test || warning "Tests failed"
+}
+
+package_python-prawcore() {
+  depends=('python-requests')
+
+  cd prawcore
+  python setup.py install --root="$pkgdir" --optimize=1
+  install -Dm644 LICENSE.txt "$pkgdir"/usr/share/licenses/$pkgname/LICENSE.txt
+}
+
+package_python2-prawcore() {
+  depends=('python2-requests')
+
+  cd prawcore-py2
+  python2 setup.py install --root="$pkgdir" --optimize=1
+  install -Dm644 LICENSE.txt "$pkgdir"/usr/share/licenses/$pkgname/LICENSE.txt
+}


Property changes on: python-prawcore/trunk/PKGBUILD
___________________________________________________________________
Added: svn:keywords
## -0,0 +1 ##
+Id
\ No newline at end of property



More information about the arch-commits mailing list