summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2022-02-23 08:31:04 +0100
committerMichał Górny <mgorny@gentoo.org>2022-02-23 09:12:17 +0100
commit1b5f7b94fae9d7b3bac08490213acdfc6d16fdc0 (patch)
treebefb93681d14c73a608390628e21df5b17ee83ba /dev-python
parentdev-python/requests-cache: Bump to 0.9.3 (diff)
downloadgentoo-1b5f7b94fae9d7b3bac08490213acdfc6d16fdc0.tar.gz
gentoo-1b5f7b94fae9d7b3bac08490213acdfc6d16fdc0.tar.bz2
gentoo-1b5f7b94fae9d7b3bac08490213acdfc6d16fdc0.zip
dev-python/cmd2: Bump to 2.4.0
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'dev-python')
-rw-r--r--dev-python/cmd2/Manifest1
-rw-r--r--dev-python/cmd2/cmd2-2.4.0.ebuild58
2 files changed, 59 insertions, 0 deletions
diff --git a/dev-python/cmd2/Manifest b/dev-python/cmd2/Manifest
index 9c2f2d3a6cf7..614972e417b5 100644
--- a/dev-python/cmd2/Manifest
+++ b/dev-python/cmd2/Manifest
@@ -1 +1,2 @@
DIST cmd2-2.3.3.tar.gz 675880 BLAKE2B 216b10d7a1d2eb78106e5af51a6c996ea22ff8ef13503ace6019978152f63d5015e61ab911a839703d2b3506fea4e709d507d147b2af259cf933ad628e52be22 SHA512 30d7a82a1c3d23431a40a7e99f10a4c23227e9ab073ab1d7fd83e516f54e9c90bda10e6072b50c0a2ca435498c1060e06b32a550409721899e28d2662995a8b8
+DIST cmd2-2.4.0.tar.gz 680118 BLAKE2B 09f4893db7587dce9fd59103f8a1ef54c2b61248dd4aed313a90a390bb50e8927ef7a11dc5ca3af90b5ccf36ce16e0e18f3b555cc961a8c6862f7b8131f190ae SHA512 4ecd4c71294bee86f02b39a588c42a7232309db54459c950f77734926dedc3ec273237b9615bab6ef8a499c65442e3d6f7d2e9f159ccca021db0b450435ffbc0
diff --git a/dev-python/cmd2/cmd2-2.4.0.ebuild b/dev-python/cmd2/cmd2-2.4.0.ebuild
new file mode 100644
index 000000000000..26a05e90d1bf
--- /dev/null
+++ b/dev-python/cmd2/cmd2-2.4.0.ebuild
@@ -0,0 +1,58 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_USE_PEP517=setuptools
+PYTHON_COMPAT=( python3_{8..10} )
+
+inherit distutils-r1 virtualx
+
+DESCRIPTION="Extra features for standard library's cmd module"
+HOMEPAGE="https://github.com/python-cmd2/cmd2"
+SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux"
+
+RDEPEND="
+ dev-python/attrs[${PYTHON_USEDEP}]
+ >=dev-python/colorama-0.3.7[${PYTHON_USEDEP}]
+ >=dev-python/pyperclip-1.6[${PYTHON_USEDEP}]
+ dev-python/six[${PYTHON_USEDEP}]
+ dev-python/wcwidth[${PYTHON_USEDEP}]
+"
+# pyperclip uses clipboard backends in the following preference order:
+# pygtk, xclip, xsel, klipper, qtpy, pyqt5, pyqt4.
+# klipper is known to be broken in Xvfb, and therefore causes test
+# failures. to avoid them, we must ensure that one of the backends
+# preferred to it is available (i.e. xclip or xsel) + which(1).
+BDEPEND="
+ dev-python/setuptools_scm[${PYTHON_USEDEP}]
+ test? (
+ dev-python/pytest-mock[${PYTHON_USEDEP}]
+ sys-apps/which
+ || (
+ x11-misc/xclip
+ x11-misc/xsel
+ )
+ )
+"
+
+distutils_enable_tests pytest
+
+src_prepare() {
+ distutils-r1_src_prepare
+ sed -i -e '/--cov/d' setup.cfg || die
+}
+
+src_test() {
+ # tests rely on very specific text wrapping...
+ local -x COLUMNS=80
+ virtx distutils-r1_src_test
+}
+
+python_test() {
+ epytest -p no:pytest-qt || die
+}