Date: Sunday, October 23, 2022 @ 16:54:30
Author: segaja
Revision: 1334346
python-libvcs 0.19.0-1
Added:
python-libvcs/
python-libvcs/repos/
python-libvcs/trunk/
python-libvcs/trunk/PKGBUILD
----------+
PKGBUILD | 48 ++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 48 insertions(+)
Added: python-libvcs/trunk/PKGBUILD
===================================================================
--- python-libvcs/trunk/PKGBUILD (rev 0)
+++ python-libvcs/trunk/PKGBUILD 2022-10-23 16:54:30 UTC (rev 1334346)
@@ -0,0 +1,48 @@
+# Maintainer: Andreas 'Segaja' Schleifer <segaja at archlinux dot org>
+
+_name='libvcs'
+pkgname="python-${_name}"
+pkgver=0.19.0
+pkgrel=1
+pkgdesc='Lite, typed, pythonic utilities for git, svn, mercurial, etc'
+arch=('any')
+url='https://libvcs.git-pull.com/'
+license=('MIT')
+depends=('python' 'python-typing_extensions')
+makedepends=('python-build' 'python-installer' 'python-poetry-core')
+checkdepends=('git' 'mercurial' 'python-pytest' 'python-pytest-mock'
'subversion')
+optdepends=(
+ 'git: for git repository support'
+ 'mercurial: for mercurial repository support'
+ 'subversion: for subversion repository support'
+ 'python-pytest: for pytest plugin'
+)
+source=("https://github.com/vcs-python/libvcs/archive/v${pkgver}/${pkgname}-${pkgver}.tar.gz")
+sha512sums=('6c8941cb37509c165f977f56818ec1b4115749b5ae27b85ec432033a3ea50b922891d66292d6e30f453030111b47e2042a2f7c5085c70ab71e999a3110e162d9')
+
+build() {
+ cd "${_name}-${pkgver}"
+
+ python -m build --wheel --skip-dependency-check --no-isolation
+}
+
+check() {
+ cd "${_name}-${pkgver}"
+
+ local _site_packages="$(python -c "import site;
print(site.getsitepackages()[0])")"
+
+ python -m installer --destdir=test_dir dist/*.whl
+
+ export PYTHONPATH="test_dir${_site_packages}:${PYTHONPATH}"
+
+ pytest -vv tests
+}
+
+package() {
+ cd "${_name}-${pkgver}"
+
+ python -m installer --destdir="${pkgdir}" dist/*.whl
+
+ install --verbose -D --mode=0644 LICENSE --target-directory
"${pkgdir}/usr/share/licenses/${pkgname}"
+ install --verbose -D --mode=0644 *.md CHANGES MIGRATION --target-directory
"${pkgdir}/usr/share/doc/${pkgname}"
+}