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

Felix Yan felixonmars at archlinux.org
Mon Nov 9 19:53:16 UTC 2020


    Date: Monday, November 9, 2020 @ 19:53:16
  Author: felixonmars
Revision: 748098

archrelease: copy trunk to community-staging-any

Added:
  python-pastel/repos/community-staging-any/
  python-pastel/repos/community-staging-any/PKGBUILD
    (from rev 748096, python-pastel/trunk/PKGBUILD)

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

Copied: python-pastel/repos/community-staging-any/PKGBUILD (from rev 748096, python-pastel/trunk/PKGBUILD)
===================================================================
--- community-staging-any/PKGBUILD	                        (rev 0)
+++ community-staging-any/PKGBUILD	2020-11-09 19:53:16 UTC (rev 748098)
@@ -0,0 +1,42 @@
+# Maintainer: Eli Schwartz <eschwartz at archlinux.org>
+
+_pkgname=pastel
+pkgname=python-pastel
+pkgver=0.2.0
+pkgrel=2
+pkgdesc="Bring colors to your terminal"
+arch=('any')
+url="https://github.com/sdispater/${_pkgname}"
+license=('MIT')
+depends=('python')
+makedepends=('python-dephell' 'python-setuptools')
+checkdepends=('python-pytest')
+source=("https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/${_pkgname}/${_pkgname}-${pkgver}.tar.gz")
+sha256sums=('46155fc523bdd4efcd450bbcb3f2b94a6e3b25edc0eb493e081104ad09e1ca36')
+b2sums=('dbf758eba2eaf81d6aaa7cf2eec7d3055f22a30d6caa7814e0a49e8d6b93c387efe67096ea3eb126a0abec71917b3cd8bb627bfc16ed2be089d406ae073c5b24')
+
+prepare() {
+    cd "${srcdir}"/${_pkgname}-${pkgver}
+
+    # poetry does not generate correct setup.py, nuke it and recreate from scratch
+    dephell deps convert --from pyproject.toml --to setup.py
+}
+
+build(){
+    cd "${srcdir}"/${_pkgname}-${pkgver}
+
+    python setup.py build
+}
+
+check() {
+    cd "${srcdir}"/${_pkgname}-${pkgver}
+
+    python -m pytest
+}
+
+package() {
+    cd "${srcdir}"/${_pkgname}-${pkgver}
+
+    python setup.py install --root="${pkgdir}" --optimize=1 --skip-build
+    install -Dm644 LICENSE "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
+}



More information about the arch-commits mailing list