[arch-commits] Commit in python-configargparse/repos (2 files)

Felix Yan felixonmars at archlinux.org
Fri May 11 08:21:57 UTC 2018


    Date: Friday, May 11, 2018 @ 08:21:57
  Author: felixonmars
Revision: 320624

archrelease: copy trunk to community-testing-any

Added:
  python-configargparse/repos/community-testing-any/
  python-configargparse/repos/community-testing-any/PKGBUILD
    (from rev 320623, python-configargparse/trunk/PKGBUILD)

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

Copied: python-configargparse/repos/community-testing-any/PKGBUILD (from rev 320623, python-configargparse/trunk/PKGBUILD)
===================================================================
--- community-testing-any/PKGBUILD	                        (rev 0)
+++ community-testing-any/PKGBUILD	2018-05-11 08:21:57 UTC (rev 320624)
@@ -0,0 +1,57 @@
+# $Id$
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+pkgbase=python-configargparse
+pkgname=('python-configargparse' 'python2-configargparse')
+pkgver=0.13.0
+pkgrel=1
+pkgdesc='A drop-in replacement for argparse that allows options to also be set via config files and/or environment variables'
+arch=('any')
+url='https://github.com/zorro3/ConfigArgParse'
+license=('MIT')
+makedepends=('python-setuptools' 'python2-setuptools')
+checkdepends=('python-yaml' 'python2-yaml')
+source=("$pkgbase-$pkgver.tar.gz::https://github.com/bw2/ConfigArgParse/archive/$pkgver.tar.gz")
+sha512sums=('797c5edbc51353797204152b5c908ddb4e883a98f247430448d774957fd841286ea1a3cb87db3186e683a65f566cfce0a815e4bd558b9c823d9226d856341ca9')
+
+prepare() {
+  cp -a ConfigArgParse-$pkgver{,-py2}
+}
+
+build() {
+  cd "$srcdir"/ConfigArgParse-$pkgver
+  python setup.py build
+
+  cd "$srcdir"/ConfigArgParse-$pkgver-py2
+  python2 setup.py build
+}
+
+check() {
+  cd "$srcdir"/ConfigArgParse-$pkgver
+  python setup.py test
+
+  cd "$srcdir"/ConfigArgParse-$pkgver-py2
+  python2 setup.py test || warning "Tests failed"
+}
+
+package_python-configargparse() {
+  depends=('python')
+  optdepends=('python-yaml: for YAML support')
+
+  cd ConfigArgParse-$pkgver
+
+  python setup.py install --root="$pkgdir" --optimize=1
+  install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+}
+
+package_python2-configargparse() {
+  depends=('python2')
+  optdepends=('python2-yaml: for YAML support')
+
+  cd ConfigArgParse-$pkgver-py2
+
+  python2 setup.py install --root="$pkgdir" --optimize=1
+  install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+}
+
+# vim:set ts=2 sw=2 et:



More information about the arch-commits mailing list