]> git.bzium.org - embe/overlay.git/blobdiff - dev-python/cloudflare/cloudflare-2.8.14.ebuild
dev-python/cloudflare: bump to 2.8.14 with Python 3.9 support
[embe/overlay.git] / dev-python / cloudflare / cloudflare-2.8.14.ebuild
diff --git a/dev-python/cloudflare/cloudflare-2.8.14.ebuild b/dev-python/cloudflare/cloudflare-2.8.14.ebuild
new file mode 100644 (file)
index 0000000..36479aa
--- /dev/null
@@ -0,0 +1,46 @@
+# Copyright 2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python3_{6,7,8,9} )
+DISTUTILS_USE_SETUPTOOLS=rdepend
+inherit distutils-r1
+
+MY_PN="python-${PN}"
+MY_P="${MY_PN}-${PV}"
+
+DESCRIPTION="Python wrapper for the Cloudflare Client API v4"
+HOMEPAGE="https://github.com/cloudflare/python-cloudflare"
+SRC_URI="https://github.com/cloudflare/${MY_PN}/archive/${PV}.tar.gz -> ${MY_P}.tar.gz"
+
+LICENSE="MIT-with-advertising"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="examples"
+
+RDEPEND="
+       dev-python/requests[${PYTHON_USEDEP}]
+       dev-python/pyyaml[${PYTHON_USEDEP}]
+       dev-python/jsonlines[${PYTHON_USEDEP}]
+       dev-python/beautifulsoup:4[${PYTHON_USEDEP}]
+"
+
+S="${WORKDIR}/${MY_P}"
+
+src_prepare() {
+       sed -i -e "s:packages=.*:packages=['cli4', 'CloudFlare'],:" -i setup.py || die
+       sed -i -e "/data_files = /d" -i setup.py || die
+       distutils-r1_src_prepare
+}
+
+python_install_all() {
+       if use examples; then
+               dodoc -r examples
+               docompress -x /usr/share/doc/${PF}/examples
+       fi
+
+       newman cli4/cli4.man cli4.1
+
+       distutils-r1_python_install_all
+}