[arch-commits] Commit in python-colorama/repos (2 files)
Felix Yan
felixonmars at archlinux.org
Fri Oct 25 16:38:10 UTC 2019
Date: Friday, October 25, 2019 @ 16:38:09
Author: felixonmars
Revision: 519508
archrelease: copy trunk to community-staging-any
Added:
python-colorama/repos/community-staging-any/
python-colorama/repos/community-staging-any/PKGBUILD
(from rev 519506, python-colorama/trunk/PKGBUILD)
----------+
PKGBUILD | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 55 insertions(+)
Copied: python-colorama/repos/community-staging-any/PKGBUILD (from rev 519506, python-colorama/trunk/PKGBUILD)
===================================================================
--- community-staging-any/PKGBUILD (rev 0)
+++ community-staging-any/PKGBUILD 2019-10-25 16:38:09 UTC (rev 519508)
@@ -0,0 +1,55 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+# Contributor: Alexander Duscheleit <jinks at archlinux.us>
+
+pkgbase=python-colorama
+pkgname=('python-colorama' 'python2-colorama')
+pkgver=0.4.1
+pkgrel=2
+pkgdesc="Python API for cross-platform colored terminal text."
+arch=('any')
+url="https://pypi.python.org/pypi/colorama"
+license=('BSD')
+makedepends=('python-setuptools' 'python2-setuptools')
+checkdepends=('python-mock' 'python2-mock')
+source=("$pkgbase-$pkgver.tar.gz::https://github.com/tartley/colorama/archive/$pkgver.tar.gz")
+sha512sums=('006069859ca05ec8a6808860ca73ab541b246e6e6443b1bc8426973beaa5268660b48994f21edb6492fe97c4b9d29949b874b861ec200b1756d40e8abda8dee0')
+
+prepare() {
+ cp -a colorama-$pkgver{,-py2}
+}
+
+build() {
+ cd "$srcdir"/colorama-$pkgver
+ python setup.py build
+
+ cd "$srcdir"/colorama-$pkgver-py2
+ python2 setup.py build
+}
+
+check() {
+ cd "$srcdir"/colorama-$pkgver
+ python -m unittest discover -p *_test.py || warning "Tests failed"
+
+ cd "$srcdir"/colorama-$pkgver-py2
+ python2 -m unittest discover -p *_test.py || warning "Tests failed"
+}
+
+package_python-colorama() {
+ depends=('python')
+
+ cd colorama-$pkgver
+ python setup.py install --root="$pkgdir" --optimize=1
+
+ install -Dm644 LICENSE.txt "$pkgdir"/usr/share/licenses/$pkgname/LICENSE.txt
+}
+
+package_python2-colorama() {
+ depends=('python2')
+
+ cd colorama-$pkgver-py2
+ python2 setup.py install --root="$pkgdir" --optimize=1
+
+ install -Dm644 LICENSE.txt "$pkgdir"/usr/share/licenses/$pkgname/LICENSE.txt
+}
+
+# vim:set ts=2 sw=2 et:
More information about the arch-commits
mailing list