1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
5 PYTHON_COMPAT=( python{2_7,3_6} )
9 if [[ ${PV} == *9999* ]]; then
13 DESCRIPTION="Python client for rqlite"
14 EGIT_REPO_URI="https://github.com/rqlite/pyrqlite.git"
15 HOMEPAGE="https://github.com/rqlite/pyrqlite"
16 SRC_URI="${EGIT_REPO_URI%.git}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
20 KEYWORDS="~amd64 ~x86"
22 RESTRICT="!test? ( test )"
24 DEPEND="dev-python/setuptools[${PYTHON_USEDEP}]
26 dev-python/pytest[${PYTHON_USEDEP}]
27 dev-python/pytest-cov[${PYTHON_USEDEP}]
28 dev-python/pylint[${PYTHON_USEDEP}]
32 sed -e "s:^__version__ = .*:__version__ = '${PV}':" -i src/${PN}/constants.py || die
33 distutils-r1_src_prepare
37 esetup.py test || die "tests failed"
38 esetup.py lint -f text -E || die "pylint failed"