archrelease: copy trunk to community-any
[ArchLinux/community.git] / python-poetry-dynamic-versioning / repos / community-any / PKGBUILD
blob004d9fc6df25e9768c6f6132818edec4fed1236b
1 # Maintainer: George Rawlinson <grawlinson@archlinux.org>
3 pkgname=python-poetry-dynamic-versioning
4 pkgver=0.21.5
5 pkgrel=1
6 pkgdesc='Plugin for Poetry to enable dynamic versioning based on VCS tags'
7 arch=('any')
8 url='https://github.com/mtkennerly/poetry-dynamic-versioning'
9 license=('MIT')
10 depends=(
11   'python'
12   'python-dunamai'
13   'python-tomlkit'
14   'python-jinja'
15   'python-poetry'
16   'python-cleo'
17   'python-poetry-core'
18   'python-packaging'
20 makedepends=(
21   'git'
22   'python-build'
23   'python-installer'
24   'python-poetry-core'
26 checkdepends=(
27   'python-pytest'
28   'python-pytest-cov'
30 _commit='1ba52145bc6645e7efc049b0fb550acfd073780e'
31 source=("$pkgname::git+$url#commit=$_commit")
32 b2sums=('SKIP')
34 pkgver() {
35   cd "$pkgname"
37   git describe --tags | sed 's/^v//'
40 build() {
41   cd "$pkgname"
43   python -m build --wheel --no-isolation
46 check() {
47   cd "$pkgname"
49   # integration tests are sketchy
50   pytest -v tests/test_unit.py
53 package() {
54   cd "$pkgname"
56   python -m installer --destdir="$pkgdir" dist/*.whl
58   # license
59   install -vDm644 -t "$pkgdir/usr/share/licenses/$pkgname" LICENSE