1 |
commit: 0649fbd7ace6eeb0fbdf5c992129abc33f58f0a6 |
2 |
Author: Zac Medico <zmedico <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sat Jun 19 21:14:57 2021 +0000 |
4 |
Commit: Zac Medico <zmedico <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat Jun 19 22:12:17 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0649fbd7 |
7 |
|
8 |
dev-python/yamlpath: Initial import |
9 |
|
10 |
Package-Manager: Portage-3.0.20, Repoman-3.0.3 |
11 |
Signed-off-by: Zac Medico <zmedico <AT> gentoo.org> |
12 |
|
13 |
dev-python/yamlpath/Manifest | 1 + |
14 |
dev-python/yamlpath/metadata.xml | 14 ++++++++ |
15 |
dev-python/yamlpath/yamlpath-3.6.0.ebuild | 56 +++++++++++++++++++++++++++++++ |
16 |
3 files changed, 71 insertions(+) |
17 |
|
18 |
diff --git a/dev-python/yamlpath/Manifest b/dev-python/yamlpath/Manifest |
19 |
new file mode 100644 |
20 |
index 00000000000..66b3b1648fb |
21 |
--- /dev/null |
22 |
+++ b/dev-python/yamlpath/Manifest |
23 |
@@ -0,0 +1 @@ |
24 |
+DIST yamlpath-3.6.0.tar.gz 214052 BLAKE2B 6b969a8c6e63f879e9c9f17f4542a48e55987835f99f10867577d93107813b684cfa0bf647f6d11b8ef8f02438e7e72f847eb0a29761a169950f8a5c6ee0ec5b SHA512 377cd281b4e7df251bbb298977c258e1a547ce4726ad321e5bf500242884049d3e052b83b83b72d477111fe121bd483d5122427498a5ebf784ab6d86d92d6ed6 |
25 |
|
26 |
diff --git a/dev-python/yamlpath/metadata.xml b/dev-python/yamlpath/metadata.xml |
27 |
new file mode 100644 |
28 |
index 00000000000..096a53d7d98 |
29 |
--- /dev/null |
30 |
+++ b/dev-python/yamlpath/metadata.xml |
31 |
@@ -0,0 +1,14 @@ |
32 |
+<?xml version="1.0" encoding="UTF-8"?> |
33 |
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> |
34 |
+<pkgmetadata> |
35 |
+ <upstream> |
36 |
+ <bugs-to>https://github.com/wwkimball/yamlpath/issues</bugs-to> |
37 |
+ <changelog>https://raw.githubusercontent.com/wwkimball/yamlpath/master/CHANGES</changelog> |
38 |
+ <doc>https://github.com/wwkimball/yamlpath/wiki</doc> |
39 |
+ <remote-id type="pypi">yamlpath</remote-id> |
40 |
+ <remote-id type="github">wwkimball/yamlpath</remote-id> |
41 |
+ </upstream> |
42 |
+ <maintainer type="person"> |
43 |
+ <email>zmedico@g.o</email> |
44 |
+ </maintainer> |
45 |
+</pkgmetadata> |
46 |
|
47 |
diff --git a/dev-python/yamlpath/yamlpath-3.6.0.ebuild b/dev-python/yamlpath/yamlpath-3.6.0.ebuild |
48 |
new file mode 100644 |
49 |
index 00000000000..ac88b3e28ff |
50 |
--- /dev/null |
51 |
+++ b/dev-python/yamlpath/yamlpath-3.6.0.ebuild |
52 |
@@ -0,0 +1,56 @@ |
53 |
+# Copyright 2021 Gentoo Authors |
54 |
+# Distributed under the terms of the GNU General Public License v2 |
55 |
+ |
56 |
+EAPI=7 |
57 |
+PYTHON_COMPAT=( python3_{8..10} ) |
58 |
+DISTUTILS_USE_SETUPTOOLS=rdepend |
59 |
+ |
60 |
+inherit distutils-r1 |
61 |
+ |
62 |
+DESCRIPTION="Command-line processors for YAML/JSON/Compatible data." |
63 |
+HOMEPAGE="https://github.com/wwkimball/yamlpath https://github.com/wwkimball/yamlpath/wiki" |
64 |
+SRC_URI="https://github.com/wwkimball/yamlpath/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" |
65 |
+LICENSE="ISC" |
66 |
+SLOT="0" |
67 |
+KEYWORDS="~amd64" |
68 |
+IUSE="test" |
69 |
+RESTRICT="test" |
70 |
+RDEPEND=" |
71 |
+ dev-python/ruamel-yaml[${PYTHON_USEDEP}] |
72 |
+" |
73 |
+BDEPEND=" |
74 |
+ ${RDEPEND} |
75 |
+ test? ( dev-python/pytest[${PYTHON_USEDEP}] ) |
76 |
+" |
77 |
+ |
78 |
+python_prepare_all() { |
79 |
+ local sed_args |
80 |
+ |
81 |
+ sed_args=( |
82 |
+ -e 's|\("ruamel\.yaml\)[^"]*|\1|' |
83 |
+ -e '/pytest-cov/d' |
84 |
+ -e '/pytest-console-scripts/d' |
85 |
+ ) |
86 |
+ sed "${sed_args[@]}" -i setup.py || die |
87 |
+ |
88 |
+ distutils-r1_python_prepare_all |
89 |
+} |
90 |
+ |
91 |
+python_test() { |
92 |
+ PYTHONPATH="${S}" py.test -v tests || die "Tests failed under ${EPYTHON}" |
93 |
+} |
94 |
+ |
95 |
+yamlpath_post_src_install() { |
96 |
+ local sitedir=$(python_get_sitedir) |
97 |
+ [[ -d ${D}${sitedir} ]] || die "${D}${sitedir}: No such directory" |
98 |
+ insinto "${sitedir}/yamlpath" |
99 |
+ doins -r "${S}/yamlpath/patches" |
100 |
+ python_optimize "${D}${sitedir}" || die |
101 |
+} |
102 |
+ |
103 |
+src_install() { |
104 |
+ find "${WORKDIR}" -name tests -print0 | xargs -0 rm -rf || die |
105 |
+ distutils-r1_src_install |
106 |
+ |
107 |
+ python_foreach_impl yamlpath_post_src_install |
108 |
+} |