1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
6 DISTUTILS_SINGLE_IMPL=1
7 PYTHON_COMPAT=( python{3_6,3_7} )
11 DESCRIPTION="Initial tagging script for Notmuch"
12 HOMEPAGE="https://github.com/afewmail/afew"
13 SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
17 KEYWORDS="~amd64 ~x86"
21 $(python_gen_cond_dep '
22 dev-python/chardet[${PYTHON_MULTI_USEDEP}]
23 dev-python/dkimpy[${PYTHON_MULTI_USEDEP}]
24 net-mail/notmuch[python,${PYTHON_MULTI_USEDEP}]
27 $(python_gen_cond_dep '
28 dev-python/sphinx[${PYTHON_MULTI_USEDEP}]
33 python_prepare_all() {
35 -e "s/^([[:space:]]+)use_scm_version=.*,$/\1version='${PV}',/" \
36 -e "/^([[:space:]]+)setup_requires=.*,$/d" \
38 distutils-r1_python_prepare_all
41 python_compile_all() {
42 esetup.py build_sphinx -b man --build-dir=docs/build
43 use doc && esetup.py build_sphinx -b html --build-dir=docs/build
46 python_install_all() {
47 doman docs/build/man/*
48 dodoc afew/defaults/afew.config
49 use doc && local HTML_DOCS=( docs/build/html/. )