summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMorgenstern2019-11-14 19:11:14 +1300
committerMorgenstern2019-11-14 19:11:14 +1300
commitaa17c0d8b413ad5df34c1a3262f7869fca73ca3c (patch)
tree8808d718e56b8f13f572ad27da6a5b15b33ba230
parent58acfb8577cd8980c2a6df7417e5dce8ace8178e (diff)
downloadaur-aa17c0d8b413ad5df34c1a3262f7869fca73ca3c.tar.gz
Initial commit
-rw-r--r--.SRCINFO13
-rw-r--r--PKGBUILD40
2 files changed, 37 insertions, 16 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 643a21d58f02..4ea1865a0896 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,14 +1,17 @@
pkgbase = python2-colorclass
- pkgdesc = Colorful worry-free console applications for Linux, Mac OS X, and Windows
+ pkgdesc = Yet another ANSI color text library for colorful worry-free console applications, python2 version
pkgver = 2.2.0
- pkgrel = 1
- url = http://pypi.python.org/pypi/colorclass
+ pkgrel = 5
+ url = https://github.com/Robpol86/colorclass
arch = any
license = MIT
+ checkdepends = python2-pytest
+ checkdepends = python2-docopt
makedepends = python2-setuptools
depends = python2
- source = https://pypi.io/packages/source/c/colorclass/colorclass-2.2.0.tar.gz
- md5sums = 060139e93e31faafeb5d4bdfd6ea0bb8
+ replaces = python2-colorclass<=2.2.0-4
+ source = python2-colorclass-2.2.0.tar.gz::https://github.com/Robpol86/colorclass/archive/v2.2.0.tar.gz
+ sha512sums = c627cdf6abdb5a60e9ecc1fb3b669898edc027fdc3f8cde31be2e10402ee308c2067fcd50d1228759e93fc58c521b7fc12e6b259233a17cf99f55cda26279fed
pkgname = python2-colorclass
diff --git a/PKGBUILD b/PKGBUILD
index fcb218f6fbb5..a1cdc71fd678 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,23 +1,41 @@
-# Maintainer: Cedric Girard <girard.cedric@gmail.com>
-_pythonmod=colorclass
-pkgname=python2-colorclass
+# Maintainer: Morgenstern <charles [at] charlesbwise [dot] com>
+# Contributor: Levente Polyak <anthraxx [at] archlinux [dot] org>
+
+_pyname=colorclass
+pkgname=('python2-colorclass')
pkgver=2.2.0
-pkgrel=1
-pkgdesc="Colorful worry-free console applications for Linux, Mac OS X, and Windows"
+pkgrel=5
+pkgdesc='Yet another ANSI color text library for colorful worry-free console applications, python2 version'
+url='https://github.com/Robpol86/colorclass'
arch=('any')
-url="http://pypi.python.org/pypi/${_pythonmod}"
license=('MIT')
depends=('python2')
makedepends=('python2-setuptools')
-source=("https://pypi.io/packages/source/${_pythonmod:0:1}/${_pythonmod}/${_pythonmod}-$pkgver.tar.gz")
-md5sums=('060139e93e31faafeb5d4bdfd6ea0bb8')
+checkdepends=('python2-pytest' 'python2-docopt')
+replaces=('python2-colorclass<=2.2.0-4')
+source=(${pkgname}-${pkgver}.tar.gz::https://github.com/Robpol86/colorclass/archive/v${pkgver}.tar.gz)
+sha512sums=('c627cdf6abdb5a60e9ecc1fb3b669898edc027fdc3f8cde31be2e10402ee308c2067fcd50d1228759e93fc58c521b7fc12e6b259233a17cf99f55cda26279fed')
+
+prepare() {
+ cd ${_pyname}-${pkgver}
+ sed -i -e s/python/python2/g example.py
+}
build() {
- cd ${srcdir}/${_pythonmod}-$pkgver
+ cd ${_pyname}-${pkgver}
python2 setup.py build
}
+check() {
+ cd ${_pyname}-${pkgver}
+ py.test2
+}
+
package() {
- cd ${srcdir}/${_pythonmod}-$pkgver
- python2 setup.py install --root=${pkgdir}
+ cd ${_pyname}-${pkgver}
+ python2 setup.py install --root="${pkgdir}" --prefix=/usr -O1 --skip-build
+ install -Dm 644 LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}"
+ install -Dm 644 README.rst example.py -t "${pkgdir}/usr/share/doc/${pkgname}"
}
+
+# vim: ts=2 sw=2 et: