void-packages/srcpkgs/hatch/template

38 lines
1.5 KiB
Bash

# Template file for 'hatch'
pkgname=hatch
version=1.5.0
revision=2
build_style=python3-pep517
# ignore backend tests, because updating hatchling when there is no new hatch
# version yet breaks these in hatch.
make_check_args="--deselect tests/cli/test_root.py::TestFreshInstallation::test_config_file_creation_verbose
--deselect tests/cli/run/test_run.py::test_scripts_no_environment
--ignore tests/backend
--ignore backend/tests"
_deps="python3-click hatchling python3-httpx python3-hyperlink python3-keyring
python3-pexpect python3-platformdirs python3-pyperclip python3-rich
python3-shellingham python3-tomli-w python3-tomlkit python3-userpath
python3-virtualenv"
hostmakedepends="hatchling ${_deps}"
depends="${_deps}"
checkdepends="${_deps} python3-pytest python3-pytest-mock
python3-pytest-xdist git python3-pip"
short_desc="Modern, extensible Python project management "
maintainer="Jan Christian Grünhage <jan.christian@gruenhage.xyz>"
license="MIT"
homepage="https://hatch.pypa.io/latest/"
changelog="https://raw.githubusercontent.com/pypa/hatch/master/docs/history.md"
distfiles="${PYPI_SITE}/h/${pkgname}/${pkgname}-${version}.tar.gz"
checksum=cdd9bdcf6bd8fccbde26c4f84f8fc14859d912d078cd0348d350c973bed073f4
make_check_pre="env PYTHONPATH=./src"
post_install() {
vlicense LICENSE.txt
for shell in zsh bash fish; do
PYTHONPATH="${DESTDIR}/${py3_sitelib}" PATH="${DESTDIR}/usr/bin:${PATH}" \
_HATCH_COMPLETE="${shell}_source" hatch > "hatch.${shell}"
vcompletion "hatch.${shell}" "${shell}"
done
}