commit: 141153ee9444becebe8b512ef043e258436e8ab5 Author: Matt Jolly <kangie <AT> gentoo <DOT> org> AuthorDate: Tue Jul 30 04:00:57 2024 +0000 Commit: Matt Jolly <kangie <AT> gentoo <DOT> org> CommitDate: Sun Dec 8 23:34:01 2024 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=141153ee
app-eselect/eselect-repository: add 'git' and 'mercurial' USE. We have documentation in the wiki for using eselect-repository to (e.g.) enable syncing ::gentoo via Git, however nothing actually ensures that appropriate sync types are available. After discussion with mgorny added the two USE flags, with 'git' being enabled by default. Closes: https://github.com/gentoo/gentoo/pull/37764 Closes: https://github.com/gentoo/gentoo/pull/39631 Signed-off-by: Matt Jolly <kangie <AT> gentoo.org> .../eselect-repository-14-r1.ebuild | 60 ++++++++++++++++++++++ app-eselect/eselect-repository/metadata.xml | 3 ++ 2 files changed, 63 insertions(+) diff --git a/app-eselect/eselect-repository/eselect-repository-14-r1.ebuild b/app-eselect/eselect-repository/eselect-repository-14-r1.ebuild new file mode 100644 index 000000000000..e4febaebdadd --- /dev/null +++ b/app-eselect/eselect-repository/eselect-repository-14-r1.ebuild @@ -0,0 +1,60 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..13} ) +inherit python-single-r1 + +DESCRIPTION="Manage repos.conf via eselect" +HOMEPAGE="https://github.com/projg2/eselect-repository/" +SRC_URI=" + https://github.com/projg2/eselect-repository/archive/v${PV}.tar.gz + -> ${P}.tar.gz +" + +LICENSE="BSD-2" +SLOT="0" +KEYWORDS="~alpha amd64 arm arm64 hppa ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~arm64-macos ~x64-macos" +IUSE="+git mercurial test" +RESTRICT="!test? ( test )" +REQUIRED_USE=${PYTHON_REQUIRED_USE} + +RDEPEND=" + ${PYTHON_DEPS} + app-admin/eselect + $(python_gen_cond_dep ' + dev-python/lxml[${PYTHON_USEDEP}] + ') + net-misc/wget + git? ( dev-vcs/git ) + mercurial? ( dev-vcs/mercurial ) +" +BDEPEND=" + test? ( + $(python_gen_cond_dep ' + dev-python/pytest[${PYTHON_USEDEP}] + ') + ) +" + +src_compile() { + MAKEARGS=( + PREFIX="${EPREFIX}/usr" + SYSCONFDIR="${EPREFIX}/etc" + SHAREDSTATEDIR="${EPREFIX}/var" + ESELECTDIR="${EPREFIX}/usr/share/eselect/modules" + ) + + emake "${MAKEARGS[@]}" + python_fix_shebang eselect-repo-helper +} + +src_test() { + epytest +} + +src_install() { + emake "${MAKEARGS[@]}" DESTDIR="${D}" install + einstalldocs +} diff --git a/app-eselect/eselect-repository/metadata.xml b/app-eselect/eselect-repository/metadata.xml index affa96ed287a..889aeb82b1a5 100644 --- a/app-eselect/eselect-repository/metadata.xml +++ b/app-eselect/eselect-repository/metadata.xml @@ -5,6 +5,9 @@ <email>[email protected]</email> <name>Michał Górny</name> </maintainer> + <use> + <flag name="mercurial">Support mercurial sync-type.</flag> + </use> <upstream> <remote-id type="github">projg2/eselect-repository</remote-id> </upstream>
