summaryrefslogtreecommitdiff
path: root/dev-python/python-betterproto
diff options
context:
space:
mode:
Diffstat (limited to 'dev-python/python-betterproto')
-rw-r--r--dev-python/python-betterproto/Manifest1
-rw-r--r--dev-python/python-betterproto/metadata.xml12
-rw-r--r--dev-python/python-betterproto/python-betterproto-2.0.0_beta4.ebuild53
-rw-r--r--dev-python/python-betterproto/python-betterproto-9999.ebuild53
4 files changed, 119 insertions, 0 deletions
diff --git a/dev-python/python-betterproto/Manifest b/dev-python/python-betterproto/Manifest
new file mode 100644
index 000000000000..07be9d4d8816
--- /dev/null
+++ b/dev-python/python-betterproto/Manifest
@@ -0,0 +1 @@
+DIST python-betterproto-2.0.0_beta4.tar.gz 137744 BLAKE2B 55cde21cca516ae935d8ff99303e3dcf78d952c470eaac2f91b5fa1dc20069e0ad150a0b59518d450c897547a3b3025d9ad683294adca5be6d66f06ba8034615 SHA512 10fc514e7a6d1ab87dd44e00d75d8f48752fa1ece26ccc671eeac502164aee2b8e4a30ec908e4abbb4b1c6671c72fc982764d74ccd0ac0f099d3533dcde64352
diff --git a/dev-python/python-betterproto/metadata.xml b/dev-python/python-betterproto/metadata.xml
new file mode 100644
index 000000000000..f52a95675fe8
--- /dev/null
+++ b/dev-python/python-betterproto/metadata.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://liguros.gitlab.io/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>antonin.riha@protonmail.com</email>
+ <name>Antonín Říha</name>
+ </maintainer>
+ <upstream>
+ <bugs-to>https://github.com/danielgtaylor/python-betterproto/issues</bugs-to>
+ </upstream>
+ <origin>gentoo-guru-overlay</origin>
+</pkgmetadata> \ No newline at end of file
diff --git a/dev-python/python-betterproto/python-betterproto-2.0.0_beta4.ebuild b/dev-python/python-betterproto/python-betterproto-2.0.0_beta4.ebuild
new file mode 100644
index 000000000000..47b97da44a44
--- /dev/null
+++ b/dev-python/python-betterproto/python-betterproto-2.0.0_beta4.ebuild
@@ -0,0 +1,53 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_USE_PEP517=poetry
+PYTHON_COMPAT=( python3_{7,8,9,10} pypy3 )
+
+inherit distutils-r1 optfeature
+
+DESCRIPTION="Better Protobuf / gRPC Support for Python"
+HOMEPAGE="https://github.com/danielgtaylor/python-betterproto"
+if [[ ${PV} == 9999 ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/danielgtaylor/python-betterproto"
+else
+ MY_PV="${PV/_beta/b}"
+ S="${WORKDIR}/${PN}-${MY_PV}"
+ SRC_URI="https://github.com/danielgtaylor/${PN}/archive/refs/tags/v${MY_PV}.tar.gz -> ${P}.tar.gz"
+ KEYWORDS="~amd64 ~x86"
+fi
+
+LICENSE="MIT"
+SLOT="0"
+
+RDEPEND="
+ >=dev-python/grpclib-0.4.1[${PYTHON_USEDEP}]
+ >=dev-python/python-dateutil-2.8.0[${PYTHON_USEDEP}]
+"
+BDEPEND="
+ test? (
+ >=dev-python/black-19.3[${PYTHON_USEDEP}]
+ >=dev-python/isort-5.10.1[${PYTHON_USEDEP}]
+ >=dev-python/grpcio-tools-1.40.0[${PYTHON_USEDEP}]
+ >=dev-python/pytest-mock-3.1.1[${PYTHON_USEDEP}]
+ >=dev-python/pytest-asyncio-0.12.0[${PYTHON_USEDEP}]
+ )
+"
+
+distutils_enable_tests pytest
+distutils_enable_sphinx docs \
+ '>=dev-python/sphinx_rtd_theme-0.5.0'
+
+python_test() {
+ "${EPYTHON}" -m tests.generate -v
+ epytest
+}
+
+pkg_postinst() {
+ optfeature "protoc compilation support" dev-python/black
+ optfeature "protoc compilation support" dev-python/isort
+ optfeature "protoc compilation support" dev-python/grpcio-tools
+}
diff --git a/dev-python/python-betterproto/python-betterproto-9999.ebuild b/dev-python/python-betterproto/python-betterproto-9999.ebuild
new file mode 100644
index 000000000000..2c0aa6026633
--- /dev/null
+++ b/dev-python/python-betterproto/python-betterproto-9999.ebuild
@@ -0,0 +1,53 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_USE_PEP517=poetry
+PYTHON_COMPAT=( python3_{7,8,9,10} pypy3 )
+
+inherit distutils-r1 optfeature
+
+DESCRIPTION="Better Protobuf / gRPC Support for Python"
+HOMEPAGE="https://github.com/danielgtaylor/python-betterproto"
+if [[ ${PV} == 9999 ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/danielgtaylor/python-betterproto"
+else
+ MY_PV="${PV/_beta/b}"
+ S="${WORKDIR}/${PN}-${MY_PV}"
+ SRC_URI="https://github.com/danielgtaylor/${PN}/archive/refs/tags/v${MY_PV}.tar.gz -> ${P}.tar.gz"
+ KEYWORDS="~amd64 ~arm64 ~loong ~mips ~x86"
+fi
+
+LICENSE="MIT"
+SLOT="0"
+
+RDEPEND="
+ >=dev-python/grpclib-0.4.1[${PYTHON_USEDEP}]
+ >=dev-python/python-dateutil-2.8.0[${PYTHON_USEDEP}]
+"
+BDEPEND="
+ test? (
+ >=dev-python/black-19.3[${PYTHON_USEDEP}]
+ >=dev-python/isort-5.10.1[${PYTHON_USEDEP}]
+ >=dev-python/grpcio-tools-1.40.0[${PYTHON_USEDEP}]
+ >=dev-python/pytest-mock-3.1.1[${PYTHON_USEDEP}]
+ >=dev-python/pytest-asyncio-0.12.0[${PYTHON_USEDEP}]
+ )
+"
+
+distutils_enable_tests pytest
+distutils_enable_sphinx docs \
+ '>=dev-python/sphinx_rtd_theme-0.5.0'
+
+python_test() {
+ "${EPYTHON}" -m tests.generate -v
+ epytest
+}
+
+pkg_postinst() {
+ optfeature "protoc compilation support" dev-python/black
+ optfeature "protoc compilation support" dev-python/isort
+ optfeature "protoc compilation support" dev-python/grpcio-tools
+}