diff options
Diffstat (limited to 'app-misc/yq')
-rw-r--r-- | app-misc/yq/Manifest | 3 | ||||
-rw-r--r-- | app-misc/yq/files/yq-2.13.0-tests.patch | 13 | ||||
-rw-r--r-- | app-misc/yq/yq-2.13.0.ebuild | 48 |
3 files changed, 64 insertions, 0 deletions
diff --git a/app-misc/yq/Manifest b/app-misc/yq/Manifest index 3bac775301ca..93563a1265e0 100644 --- a/app-misc/yq/Manifest +++ b/app-misc/yq/Manifest @@ -1,8 +1,11 @@ AUX yq-2.11.1-tests.patch 577 BLAKE2B e6a6f3fc58b9e260e095d1512cb807946c13f57b7a69f9dc8227287dad5965c94b1ace3f01383f12679455f4603c9b431a326e79e6dc7fb453d686c818bb1584 SHA512 4bb5887b1d5f826a205cfece0eaaddf50c8846cbc108dbaefc465c830d87d9ec3f313d4deeb60ee64fc7a09c1bb295747bb76d6a11c1e6bde3692ef580bbf323 +AUX yq-2.13.0-tests.patch 746 BLAKE2B 0d769a32a3e80cdc8a49e0f3575ab9da880bb0a916a564261874e6a8775b35c5570e99fad5a902bdf9bbdf5a6bb080a7bf57324aad461fb1ca7d9de4da787808 SHA512 e6bd60877d628e2fac51d5395b03f96a0cf7a5033c72a676dee8fe353425f6cc7ee585404567778d7765459ded0f7f71b6563e2343de9d520b8cde493012af01 DIST yq-2.11.1.tar.gz 20660 BLAKE2B 4b51652958121c16462304d21ebe545cca835b6c189a6d7550c7ea0ffc8b7088a02eb61ee412295d85d502a339ec3ccbc67b8dc12cd45a07246cbafa7d7feaf7 SHA512 a59a0b12ac70724bb1b857618a66b8fa38ecd35f37adce0495e74ef194f4547be8adce345f29644d43c3b32c0e680512bfcb527310e17746965f9c1db2b612c1 DIST yq-2.12.0.tar.gz 20796 BLAKE2B a314b54628e1865df68dadcbec8e59e16c1e57205e2b9f2b364bb6bee91563dc3da30c1e3a7ac9e2656899ee8ad004600291a845f59fbe13356f0cfb69de3e79 SHA512 3d6e26b674e5496e3a60678fb5b0389a6d83f4fdb519b40f5e6092f1df0023bbfb0e3b5e95dfac9b44e6001b8b35d7104aeeea6c347862313e57cc579110178d +DIST yq-2.13.0.tar.gz 21695 BLAKE2B e6d75cde2c298c19616647aeb14f1e34b1a68bb4db1b7e6f4e2619166ef10142ebd405d3c21492e4f5880c46a8d42222ce22b08afec492e97102923e6b838e2d SHA512 fd2722450606175b7d6674407c992f1f542b8b2309fcb33d4eb7d6e3dbc6dbc9e04b3dae7c4c649d814fdffaa18cbd50472672f1d1357fc58c5306de082b353a DIST yq-2.9.2.tar.gz 19177 BLAKE2B 038d813679d3583eb863577f317d834f78f614d6be595c96601a06b40c3af5d9b04234381529012328a45984b183376e0647a6b09b8a87642f8e688e39ec7a7f SHA512 a526407f4f34e9c2a0acccaf38207bbe328468419450efaf30171493123b7715c2e6dd6799679220b07bfa7bc9081ac5f758f833ddf05dfb5e1fe14286baf45c EBUILD yq-2.11.1.ebuild 1160 BLAKE2B 30d84041cc2929fabb76b6b7839c158d3cf97b498bf52b41b2cfe0a316fe8d3e12c0750631872c9f0d5a197caebbbdb2ba2f82878c320c2dc9f2b68e5911cde3 SHA512 00c0e8f5287b367945b0e1933892e7ba149cf4fe5b1426c4516589ee2145b54cb791065e5d692fcf87780cc5a6c010a85b0320373af820263e5d32a86b38ec7c EBUILD yq-2.12.0.ebuild 1159 BLAKE2B 62ffa38711ce983dc1fcf3781bc818421eadccf1092027bd4a751f487afc3a283daa9910cd89b8752699b6e06a95d413394b6332b3e3d023de7919886c24c872 SHA512 ebba91ba965089a9d4ca7bae013ae2ab3e225d5c507e57c650e722c3c80fe1768fcf65772eb1edc158d749a13a8d437e3312d7577dea220792ade89aab90af96 +EBUILD yq-2.13.0.ebuild 1130 BLAKE2B 0fb7c0e006fce21126bb1316691dd56b5421cdd43f0224ce6f1372d4e1b23b541b6a6d9efee718bb63ce5fd48dbf9a089a68320316b05ed8cf1136cde409e57f SHA512 a46165b9afb3934b7039fe60dcf2d0fbd1120c3874213c01fc0ad9cf79c0814bd64b22e8efd4ae654e9ad1e6ed623c0ba69084276c9c740bceb8318faa3ddcd0 EBUILD yq-2.9.2-r1.ebuild 1093 BLAKE2B 02dbdece9adbbd784011f5cfde704ea8d1f290d9218c99991a84bc50e6b45aedab7c6044a0bd5dc6859f3da3a3e809c7d60955b81437ba81bec6ba67719b61d0 SHA512 ed79ecbdbbda5e575d855a7ba21dac4696e539e99415a2621da290be65f11f58be4a4c839ca692847917319ddf4965c3a8c9756244239948d3fc9304d723e15c MISC metadata.xml 444 BLAKE2B 43250e8368905e7c7613ef6d9555abe4ee58c5d88f1d94dc2fc6d26c99cc71e0253ed830e82356a7cae131c0d8d70397da5e5c6fac41a11a4ed5f18879a4aaba SHA512 f14ad6182b3a82311473ff28308f9f435c2a9ecbf2f1fae996f82366d7547421923c2cebfe255574c3bc57b3d3774ed19bd896b6dda5be1d919d372e1428a143 diff --git a/app-misc/yq/files/yq-2.13.0-tests.patch b/app-misc/yq/files/yq-2.13.0-tests.patch new file mode 100644 index 000000000000..83e77ed97f8e --- /dev/null +++ b/app-misc/yq/files/yq-2.13.0-tests.patch @@ -0,0 +1,13 @@ +diff --git a/test/test.py b/test/test.py +index 6ec5e78..558187b 100755 +--- a/test/test.py ++++ b/test/test.py +@@ -121,7 +121,7 @@ class TestYq(unittest.TestCase): + self.assertEqual(self.run_yq("{}", ["--indentless", "-y", ".a=$ARGS.positional", "--args", "a", "b"]), + "a:\n- a\n- b\n") + self.assertEqual(self.run_yq("{}", ["-y", ".a=$ARGS.positional", "--args", "a", "b"]), "a:\n - a\n - b\n") +- self.assertEqual(self.run_yq("{}", [".", "--jsonargs", "a", "b"]), "") ++ #self.assertEqual(self.run_yq("{}", [".", "--jsonargs", "a", "b"]), "") + + def test_short_option_separation(self): + # self.assertEqual(self.run_yq('{"a": 1}', ["-yCcC", "."]), "a: 1\n") - Fails on 2.7 and 3.8 diff --git a/app-misc/yq/yq-2.13.0.ebuild b/app-misc/yq/yq-2.13.0.ebuild new file mode 100644 index 000000000000..43c89f52a700 --- /dev/null +++ b/app-misc/yq/yq-2.13.0.ebuild @@ -0,0 +1,48 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +PYTHON_COMPAT=( python3_{7..10} pypy3 ) + +inherit distutils-r1 + +DESCRIPTION="Command-line YAML processor - jq wrapper for YAML documents" +HOMEPAGE="https://yq.readthedocs.io/ https://github.com/kislyuk/yq/ https://pypi.org/project/yq/" +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz" +LICENSE="Apache-2.0" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="test" +RESTRICT="!test? ( test )" + +RDEPEND=" + app-misc/jq + dev-python/argcomplete[${PYTHON_USEDEP}] + >=dev-python/pyyaml-5.3.1[${PYTHON_USEDEP}] + dev-python/toml[${PYTHON_USEDEP}] + dev-python/xmltodict[${PYTHON_USEDEP}] +" +DEPEND=" + ${RDEPEND} + test? ( + dev-python/wheel[${PYTHON_USEDEP}] + ) +" + +PATCHES=( + "${FILESDIR}/yq-2.13.0-tests.patch" +) + +python_prepare_all() { + sed -e 's:unittest.main():unittest.main(verbosity=2):' \ + -i test/test.py || die + + sed -r -i 's:[[:space:]]*"coverage",:: ; s:[[:space:]]*"flake8",::' \ + setup.py || die + + distutils-r1_python_prepare_all +} + +python_test() { + "${EPYTHON}" test/test.py </dev/null || die "tests failed under ${EPYTHON}" +} |