Gentoo Archives: gentoo-commits

From: Georgy Yakovlev <gyakovlev@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-admin/yadm/
Date: Thu, 13 Jan 2022 02:27:59
Message-Id: 1642040871.5b34e0b3520ed5064147860bedf181b2d05934e1.gyakovlev@gentoo
1 commit: 5b34e0b3520ed5064147860bedf181b2d05934e1
2 Author: Alexey Zapparov <alexey <AT> zapparov <DOT> com>
3 AuthorDate: Thu Jan 13 01:39:52 2022 +0000
4 Commit: Georgy Yakovlev <gyakovlev <AT> gentoo <DOT> org>
5 CommitDate: Thu Jan 13 02:27:51 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5b34e0b3
7
8 app-admin/yadm: add 3.1.1
9
10 Co-Authored-By: Georgy Yakovlev <gyakovlev <AT> gentoo.org>
11 Package-Manager: Portage-3.0.28, Repoman-3.0.3
12 Signed-off-by: Alexey Zapparov <alexey <AT> zapparov.com>
13 Closes: https://github.com/gentoo/gentoo/pull/23723
14 Signed-off-by: Georgy Yakovlev <gyakovlev <AT> gentoo.org>
15
16 app-admin/yadm/Manifest | 1 +
17 app-admin/yadm/yadm-3.1.1.ebuild | 88 ++++++++++++++++++++++++++++++++++++++++
18 2 files changed, 89 insertions(+)
19
20 diff --git a/app-admin/yadm/Manifest b/app-admin/yadm/Manifest
21 index 2a3b64f3cdf2..6478b98da09f 100644
22 --- a/app-admin/yadm/Manifest
23 +++ b/app-admin/yadm/Manifest
24 @@ -1 +1,2 @@
25 DIST yadm-2.4.0.tar.gz 96877 BLAKE2B 462a5816e106c4502007ff34ab338904e14a9851ebcfc7ff79a32a8b11fbbe3e0b7e6538ed6b489ab67e2205c84b2250749e3091c77fa663886dc9792078a576 SHA512 43e16a9502f9dd9f6c6dba3bb5403bb048244a406d44cb42a96a43e62bf7342efd5f302304dbedede61423546787fc929f378d68da9031207e70239ec4e265ce
26 +DIST yadm-3.1.1.tar.gz 106890 BLAKE2B c85bfdaf15da8e88aea8e1b41af5396111fe95922f38c9709d09d76b6cb515d4aff99f0caaa225baf36bc408f6efe7f53e7b2febd45c78acf2b5f3c897b87290 SHA512 6be40ff6b1130be93649bb533d63ddc2dad626bb3022392863b600b31eef2529df443a9eb24915979bef2d1ea4ef04124668723ffb0ce0f86727f481a3997c74
27
28 diff --git a/app-admin/yadm/yadm-3.1.1.ebuild b/app-admin/yadm/yadm-3.1.1.ebuild
29 new file mode 100644
30 index 000000000000..b2d7cb882037
31 --- /dev/null
32 +++ b/app-admin/yadm/yadm-3.1.1.ebuild
33 @@ -0,0 +1,88 @@
34 +# Copyright 1999-2022 Gentoo Authors
35 +# Distributed under the terms of the GNU General Public License v2
36 +
37 +EAPI=8
38 +
39 +PYTHON_COMPAT=( python3_{8..10} )
40 +inherit bash-completion-r1 python-any-r1 python-utils-r1
41 +
42 +DESCRIPTION="Git based tool for managing dotfiles"
43 +HOMEPAGE="https://github.com/TheLocehiliosan/yadm"
44 +SRC_URI="https://github.com/TheLocehiliosan/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
45 +
46 +LICENSE="GPL-3+"
47 +SLOT="0"
48 +KEYWORDS="~amd64 ~ppc64 ~x86"
49 +IUSE="test"
50 +
51 +RESTRICT="!test? ( test )"
52 +
53 +RDEPEND="
54 + app-shells/bash
55 + app-crypt/gnupg
56 + dev-vcs/git
57 +"
58 +
59 +BDEPEND="
60 + test? (
61 + ${RDEPEND}
62 + ${PYTHON_DEPS}
63 + $(python_gen_any_dep '
64 + dev-python/pytest[${PYTHON_USEDEP}]
65 + ')
66 + dev-tcltk/expect
67 + )
68 +"
69 +
70 +python_check_deps() {
71 + has_version -b "dev-python/pytest[${PYTHON_USEDEP}]"
72 +}
73 +
74 +pkg_setup() {
75 + use test && python-any-r1_pkg_setup
76 +}
77 +
78 +src_compile() {
79 + emake "${PN}.md"
80 +}
81 +
82 +src_test() {
83 + # prevent system config having influence on tests
84 + local -x GIT_CONFIG_NOSYSTEM=1
85 +
86 + # prevent git branch warning, it confuses tests
87 + local -x GIT_CONFIG_GLOBAL="${HOME}/.gitconfig"
88 + git config --global init.defaultBranch master || die "setting default branch name failed"
89 +
90 + # un-hardcode path to tmp, otherwise encryption tests fail
91 + sed -i "s@^cache_dir = /tmp@cache_dir = ${TMPDIR}@" pytest.ini || die
92 +
93 + local EPYTEST_DESELECT=(
94 + test/test_alt.py # requires envtpl, not packaged
95 + test/test_compat_jinja.py # ditto
96 + test/test_unit_template_j2.py # ditto
97 + test/test_syntax.py # needs new yamllint, not packaged yet
98 + test/test_upgrade.py::test_upgrade # needs old version of yadm
99 + test/test_compat_alt.py # tests obsolete features, broken
100 + test/test_unit_template_esh.py # requires esh, not packaged
101 + test/test_encryption.py::test_symmetric_encrypt[clean-encrypt_exists-bad_phrase] # hangs in sandbox
102 + test/test_encryption.py::test_symmetric_encrypt[overwrite-encrypt_exists-bad_phrase] # ditto
103 + )
104 +
105 + epytest
106 +}
107 +
108 +src_install() {
109 + einstalldocs
110 +
111 + dobin "${PN}"
112 + doman "${PN}.1"
113 +
114 + dobashcomp completion/bash/yadm
115 +
116 + insinto /usr/share/zsh/site-functions
117 + doins completion/zsh/_${PN}
118 +
119 + insinto /usr/share/fish/vendor_completions.d
120 + doins completion/fish/${PN}.fish
121 +}