summaryrefslogtreecommitdiff
path: root/app-misc/yq
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2024-05-29 00:07:15 +0100
committerV3n3RiX <venerix@koprulu.sector>2024-05-29 00:07:15 +0100
commit5c4786a868bad6e3f46aecf32ad6c6dc5de98408 (patch)
tree1a1792815761a5b6f645c8d55b6b698e102dca48 /app-misc/yq
parent3c1648a0749c1d66b300d857e6b417c1162890da (diff)
gentoo auto-resync : 29:05:2024 - 00:07:15
Diffstat (limited to 'app-misc/yq')
-rw-r--r--app-misc/yq/Manifest9
-rw-r--r--app-misc/yq/files/yq-2.13.0-tests.patch13
-rw-r--r--app-misc/yq/metadata.xml5
-rw-r--r--app-misc/yq/yq-3.2.2.ebuild56
-rw-r--r--app-misc/yq/yq-3.4.3.ebuild (renamed from app-misc/yq/yq-3.2.3.ebuild)24
5 files changed, 29 insertions, 78 deletions
diff --git a/app-misc/yq/Manifest b/app-misc/yq/Manifest
index 2523933d13a1..6a350b19b3a7 100644
--- a/app-misc/yq/Manifest
+++ b/app-misc/yq/Manifest
@@ -1,9 +1,6 @@
-AUX yq-2.13.0-tests.patch 746 BLAKE2B 0d769a32a3e80cdc8a49e0f3575ab9da880bb0a916a564261874e6a8775b35c5570e99fad5a902bdf9bbdf5a6bb080a7bf57324aad461fb1ca7d9de4da787808 SHA512 e6bd60877d628e2fac51d5395b03f96a0cf7a5033c72a676dee8fe353425f6cc7ee585404567778d7765459ded0f7f71b6563e2343de9d520b8cde493012af01
AUX yq-3.1.2-test.patch 606 BLAKE2B 51d0578f5241400908efed53233a52fb0980e4733ad92e34ffee55e04c86d8bf34433133953420a5c00b6bb9160a5d7296a22fd710d83f7dee2d08b49d363925 SHA512 073395e7a5ed300c20da4747c0f97e7016909b79cb6dbaec482c8f56e8f1cb8dd009e439880726c48c37f148cfb3e9d3121cc072db92b05cc27400ca5ab0a198
-DIST yq-3.2.2.tar.gz 30872 BLAKE2B 4386a7972b411159ed909ccdc7c32a878d064ac5101cbddb16b0f1efe37c3791aeefda3b7c18c94e7d79fb01a4a4b43f7fbcc7c55bd275c52e08cc069523c8d3 SHA512 4472006d6997f7d620f71ade53d31e6db4051414c147db4f14cb31e0a16a0d0faf9e5c5a682cec098146bfd4e29f9e62278e4f208487e9e194d317ee82823e60
-DIST yq-3.2.3.tar.gz 31952 BLAKE2B b0c4548efa08aecc98b77b5988e5dbf652951ecfab3ab01bfbf9610151cee3c3a0b9c3139434cba3bfc08a2176a617a2c9d19c0fcf47bb8a6d3cc3886fa5de6d SHA512 8b60907536b5f3ae7c18dc157ed8ccf4632f2734803711a18b71111fbd6e6efff24ddc9c2221fb926ca99bf538c3bba14517529e6edb37bc487fb69441ad7928
DIST yq-3.4.1.tar.gz 32876 BLAKE2B 628fbb62de0c2f138133444c2f371819f920ac3d7c89787b96cb2de59eaa49f1324227d53f6d33e29dd9a9a804283339b34d87851c6f32a16a1cc94a7451a726 SHA512 d11290d44eefeae23a8e5fe3f536f714ee532a5aa1636c949a9db3e89bdf5ad5480ba5f8d6e809fa06a245de5e671844233ed64eb609e49fa3de8813ab9556cc
-EBUILD yq-3.2.2.ebuild 1192 BLAKE2B a77ed1c571276598b23ea8df3c83b6775ddd63d45a4f4b8ae276b17f927b3124985790186c478de7df87f2c3bc0fef4cbe3d0f4cb819a1d192aedf0e7e0ce221 SHA512 75f2b02da24ed2e40b8e630ce9ecc62b2f86f828d4051f8bd52b634394ca706908108dab6db2b4eb2f67ef02dd334349f7325d73cc35b3dd796bd6996609ba7c
-EBUILD yq-3.2.3.ebuild 1187 BLAKE2B 1384067b77b23d69f16be86e5572f090b62d2f78956a60549b7a0c7d94edf97cfd90898a9b7617a2ff5d0d656694a05d6d20a7b29309cedbc7a9637e1fadd720 SHA512 4f1a25f673827fa8a7cae4951c89ce889188828ff595bcc946c826231268674ad607dcdde8d1f3a1ba6395beea83acf1b72f0430a3bbca9fca1f9e506bb87b91
+DIST yq-3.4.3.tar.gz 33214 BLAKE2B a1b3d813d9761ac8a8429db3fe8efac64ade69e0d2fa9b137a1ca8c9e367a0f16b636482b6d9381e2de43392007f37388b6ab37def04739723488f271fd56d16 SHA512 db4ec57aafa1d08786ba11897040506c9f13d800cf06f76cea052d2bba88553db53627cdfcfdbbfbdec81324800114d397890759383fb4db31609727a10474eb
EBUILD yq-3.4.1.ebuild 1187 BLAKE2B 1384067b77b23d69f16be86e5572f090b62d2f78956a60549b7a0c7d94edf97cfd90898a9b7617a2ff5d0d656694a05d6d20a7b29309cedbc7a9637e1fadd720 SHA512 4f1a25f673827fa8a7cae4951c89ce889188828ff595bcc946c826231268674ad607dcdde8d1f3a1ba6395beea83acf1b72f0430a3bbca9fca1f9e506bb87b91
-MISC metadata.xml 444 BLAKE2B 43250e8368905e7c7613ef6d9555abe4ee58c5d88f1d94dc2fc6d26c99cc71e0253ed830e82356a7cae131c0d8d70397da5e5c6fac41a11a4ed5f18879a4aaba SHA512 f14ad6182b3a82311473ff28308f9f435c2a9ecbf2f1fae996f82366d7547421923c2cebfe255574c3bc57b3d3774ed19bd896b6dda5be1d919d372e1428a143
+EBUILD yq-3.4.3.ebuild 1639 BLAKE2B 62b82a8b5d32e56573bf5605d07f4e8cad270fe4260176c917d580f823c97ef1d565221382ca7537608632d2bcbf09f070b885b4ad823efd4c16e40f98f948ea SHA512 f983ec85fd38798f4efc50043f1e2518af960b68023e3f8c8be8a7ef156fdc809a2ab528263fb6af3d2c991521e2c457f0fceca8de6581d071ccbc01c8198f56
+MISC metadata.xml 533 BLAKE2B 1a6a5d05f8c3e0edc24567c4f3f7218a7a4a00d10044dbeb34d8fe8e75345300841c3da061f6110c156162cec1b01ecf2c82bad142d8b2754518a8a6c7191c99 SHA512 3c4b73caa09d72d0edc99964380572c015d9baaaf6e86775fd1648b9256183f6bc2bff10cec3a1e63554734de145b21275d4df5156ec2cad0adace955b0d830a
diff --git a/app-misc/yq/files/yq-2.13.0-tests.patch b/app-misc/yq/files/yq-2.13.0-tests.patch
deleted file mode 100644
index 83e77ed97f8e..000000000000
--- a/app-misc/yq/files/yq-2.13.0-tests.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-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/metadata.xml b/app-misc/yq/metadata.xml
index 668d57252e5d..e1ba38d97faf 100644
--- a/app-misc/yq/metadata.xml
+++ b/app-misc/yq/metadata.xml
@@ -12,4 +12,9 @@
<email>chutzpah@gentoo.org</email>
<name>Patrick McLean</name>
</maintainer>
+ <use>
+ <flag name="yq-symlink">
+ Create a yq symlink to yq-python.
+ </flag>
+ </use>
</pkgmetadata>
diff --git a/app-misc/yq/yq-3.2.2.ebuild b/app-misc/yq/yq-3.2.2.ebuild
deleted file mode 100644
index 98fbab95f2e3..000000000000
--- a/app-misc/yq/yq-3.2.2.ebuild
+++ /dev/null
@@ -1,56 +0,0 @@
-# Copyright 1999-2023 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-PYTHON_COMPAT=( python3_{9..11} pypy3 )
-DISTUTILS_USE_PEP517=setuptools
-
-inherit pypi 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/
-"
-
-LICENSE="Apache-2.0"
-SLOT="0"
-KEYWORDS="~amd64 ~arm64 ~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/xmltodict[${PYTHON_USEDEP}]
- >=dev-python/tomlkit-0.11.6[${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 -e 's:[[:space:]]*"coverage",:: ; s:[[:space:]]*"flake8",::' \
- -i setup.py || die
-
- sed -e '/license_file/ d' -i setup.cfg || die
-
- distutils-r1_python_prepare_all
-}
-
-python_test() {
- "${EPYTHON}" test/test.py </dev/null || die "tests failed under ${EPYTHON}"
-}
diff --git a/app-misc/yq/yq-3.2.3.ebuild b/app-misc/yq/yq-3.4.3.ebuild
index 5adf1f5a93d2..47a37a5e577e 100644
--- a/app-misc/yq/yq-3.2.3.ebuild
+++ b/app-misc/yq/yq-3.4.3.ebuild
@@ -3,7 +3,7 @@
EAPI=8
-PYTHON_COMPAT=( python3_{9..12} pypy3 )
+PYTHON_COMPAT=( python3_{9..13} pypy3 )
DISTUTILS_USE_PEP517=setuptools
inherit pypi distutils-r1
@@ -17,8 +17,8 @@ HOMEPAGE="
LICENSE="Apache-2.0"
SLOT="0"
-KEYWORDS="amd64 arm64 x86"
-IUSE="test"
+KEYWORDS="~amd64 ~arm64 ~x86"
+IUSE="test +yq-symlink"
RESTRICT="!test? ( test )"
RDEPEND="
@@ -27,6 +27,7 @@ RDEPEND="
>=dev-python/pyyaml-5.3.1[${PYTHON_USEDEP}]
dev-python/xmltodict[${PYTHON_USEDEP}]
>=dev-python/tomlkit-0.11.6[${PYTHON_USEDEP}]
+ yq-symlink? ( !app-misc/yq-go[yq-symlink] )
"
DEPEND="
${RDEPEND}
@@ -40,6 +41,16 @@ PATCHES=(
)
python_prepare_all() {
+ cat <<-\EOF > "${T}"/yq-python.patch
+ --- setup.py
+ +++ setup.py
+ @@ -37 +37 @@
+ - "console_scripts": ["yq=yq:cli", "xq=yq:xq_cli", "tomlq=yq:tq_cli"],
+ + "console_scripts": ["yq-python=yq:cli", "xq=yq:xq_cli", "tomlq=yq:tq_cli"],
+ EOF
+
+ eapply -p0 "${T}"/yq-python.patch
+
sed -e 's:unittest.main():unittest.main(verbosity=2):' \
-i test/test.py || die
@@ -54,3 +65,10 @@ python_prepare_all() {
python_test() {
"${EPYTHON}" test/test.py </dev/null || die "tests failed under ${EPYTHON}"
}
+
+src_install() {
+ distutils-r1_src_install
+ if use yq-symlink; then
+ dosym yq-python /usr/bin/yq
+ fi
+}