Date: Wednesday, December 2, 2020 @ 10:21:08 Author: dvzrv Revision: 769130
archrelease: copy trunk to community-any Added: python-subprocess-tee/repos/community-any/ python-subprocess-tee/repos/community-any/PKGBUILD (from rev 769129, python-subprocess-tee/trunk/PKGBUILD) ----------+ PKGBUILD | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) Copied: python-subprocess-tee/repos/community-any/PKGBUILD (from rev 769129, python-subprocess-tee/trunk/PKGBUILD) =================================================================== --- community-any/PKGBUILD (rev 0) +++ community-any/PKGBUILD 2020-12-02 10:21:08 UTC (rev 769130) @@ -0,0 +1,44 @@ +# Maintainer: David Runge <dv...@archlinux.org> + +_name=subprocess-tee +pkgname=python-subprocess-tee +pkgver=0.1.5 +pkgrel=1 +pkgdesc="A subprocess.run that works like tee" +arch=('any') +url="https://github.com/pycontribs/subprocess-tee" +license=('MIT') +depends=('python') +makedepends=('python-setuptools_scm') +checkdepends=('python-mock' 'python-pytest' 'python-pytest-xdist' 'python-rich') +optdepends=('python-rich: for rich text rendering') +source=("https://files.pythonhosted.org/packages/source/${_name::1}/${_name}/${_name}-${pkgver}.tar.gz") +sha512sums=('2d7d253623d1e4a7fca53c4d51adc0d88f73bf191ea39fd769d3c4bb8261dfc62dede468a3734aefe7dbc2f91a7d6cad2403f5e1accb046aa62247aa44234a34') +b2sums=('094453fb40ca53dc0f276cb63e2caa570602b91f0a47a3b17bba869a7b85e1b5f077c1b84521c1946dc0a1df3ee21aaa9ed7cc50cec65f9f6675fadac7f49d1c') + +prepare() { + mv -v "${_name}-${pkgver}" "$pkgname-$pkgver" + cd "$pkgname-$pkgver" + # do not require to run with python-pytest-cov + sed -e '/addopts/d' -i setup.cfg +} + +build() { + cd "$pkgname-$pkgver" + python setup.py build +} + +check() { + cd "$pkgname-$pkgver" + export PYTHONPATH="build:${PYTHONPATH}" + pytest -v +} + +package() { + cd "$pkgname-$pkgver" + python setup.py install --skip-build \ + --optimize=1 \ + --root="${pkgdir}" + install -vDm 644 README.md -t "${pkgdir}/usr/share/doc/${pkgname}/" + install -vDm 644 LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}/" +}