public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "David Roman" <davidroman96@gmail.com>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/proj/guru:master commit in: dev-util/find-work/
Date: Wed, 27 Nov 2024 14:34:56 +0000 (UTC)	[thread overview]
Message-ID: <1732630486.d13007f37a5de2b08b43586adfe70f817867e9f0.davidroman@gentoo> (raw)

commit:     d13007f37a5de2b08b43586adfe70f817867e9f0
Author:     Anna (cybertailor) Vyalkova <cyber+gentoo <AT> sysrq <DOT> in>
AuthorDate: Tue Nov 26 14:03:29 2024 +0000
Commit:     David Roman <davidroman96 <AT> gmail <DOT> com>
CommitDate: Tue Nov 26 14:14:46 2024 +0000
URL:        https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=d13007f3

dev-util/find-work: switch to click-app eclass

Signed-off-by: Anna (cybertailor) Vyalkova <cyber+gentoo <AT> sysrq.in>

 dev-util/find-work/find-work-0.990.0.ebuild | 37 +++--------------------------
 dev-util/find-work/find-work-9999.ebuild    | 37 +++--------------------------
 2 files changed, 6 insertions(+), 68 deletions(-)

diff --git a/dev-util/find-work/find-work-0.990.0.ebuild b/dev-util/find-work/find-work-0.990.0.ebuild
index d39534f36..e1cfbced2 100644
--- a/dev-util/find-work/find-work-0.990.0.ebuild
+++ b/dev-util/find-work/find-work-0.990.0.ebuild
@@ -5,7 +5,7 @@ EAPI=8
 
 PYTHON_COMPAT=( python3_{11..13} )
 DISTUTILS_USE_PEP517=hatchling
-inherit distutils-r1 shell-completion
+inherit click-app distutils-r1
 
 DESCRIPTION="Personal advice utility for Gentoo package maintainers"
 HOMEPAGE="
@@ -69,28 +69,7 @@ distutils_enable_sphinx docs \
 	dev-python/insipid-sphinx-theme \
 	dev-python/sphinx-prompt
 
-pkg_setup() {
-	DISTUTILS_ALL_SUBPHASE_IMPLS=()
-
-	# bug #944221
-	for impl in "${PYTHON_COMPAT[@]}"; do
-		use "python_targets_${impl}" && \
-			DISTUTILS_ALL_SUBPHASE_IMPLS+=( "${impl}" )
-	done
-}
-
-python_compile_all() {
-	# copy-pasted from distutils_write_namespace
-	local path="${BUILD_DIR}/install$(python_get_sitedir)/find_work/__init__.py"
-	cat > "${path}" <<-EOF || die
-		__path__ = __import__('pkgutil').extend_path(__path__, __name__)
-	EOF
-
-	emake completions BIN="${BUILD_DIR}/install${EPREFIX}/usr/bin/find-work"
-	sphinx_compile_all
-
-	rm "${path}" || die
-}
+click-app_enable_completions find-work
 
 python_test() {
 	distutils_write_namespace find_work
@@ -99,15 +78,5 @@ python_test() {
 
 src_install() {
 	distutils-r1_src_install
-
-	local mymakeargs=(
-		DESTDIR="${D}"
-		PREFIX="${EPREFIX}"/usr
-
-		BASHCOMPDIR="$(get_bashcompdir)"
-		ZSHCOMPDIR="$(get_zshcompdir)"
-		FISHCOMPDIR="$(get_fishcompdir)"
-	)
-
-	emake "${mymakeargs[@]}" install-data
+	emake DESTDIR="${D}" PREFIX="${EPREFIX}"/usr install-man
 }

diff --git a/dev-util/find-work/find-work-9999.ebuild b/dev-util/find-work/find-work-9999.ebuild
index d39534f36..e1cfbced2 100644
--- a/dev-util/find-work/find-work-9999.ebuild
+++ b/dev-util/find-work/find-work-9999.ebuild
@@ -5,7 +5,7 @@ EAPI=8
 
 PYTHON_COMPAT=( python3_{11..13} )
 DISTUTILS_USE_PEP517=hatchling
-inherit distutils-r1 shell-completion
+inherit click-app distutils-r1
 
 DESCRIPTION="Personal advice utility for Gentoo package maintainers"
 HOMEPAGE="
@@ -69,28 +69,7 @@ distutils_enable_sphinx docs \
 	dev-python/insipid-sphinx-theme \
 	dev-python/sphinx-prompt
 
-pkg_setup() {
-	DISTUTILS_ALL_SUBPHASE_IMPLS=()
-
-	# bug #944221
-	for impl in "${PYTHON_COMPAT[@]}"; do
-		use "python_targets_${impl}" && \
-			DISTUTILS_ALL_SUBPHASE_IMPLS+=( "${impl}" )
-	done
-}
-
-python_compile_all() {
-	# copy-pasted from distutils_write_namespace
-	local path="${BUILD_DIR}/install$(python_get_sitedir)/find_work/__init__.py"
-	cat > "${path}" <<-EOF || die
-		__path__ = __import__('pkgutil').extend_path(__path__, __name__)
-	EOF
-
-	emake completions BIN="${BUILD_DIR}/install${EPREFIX}/usr/bin/find-work"
-	sphinx_compile_all
-
-	rm "${path}" || die
-}
+click-app_enable_completions find-work
 
 python_test() {
 	distutils_write_namespace find_work
@@ -99,15 +78,5 @@ python_test() {
 
 src_install() {
 	distutils-r1_src_install
-
-	local mymakeargs=(
-		DESTDIR="${D}"
-		PREFIX="${EPREFIX}"/usr
-
-		BASHCOMPDIR="$(get_bashcompdir)"
-		ZSHCOMPDIR="$(get_zshcompdir)"
-		FISHCOMPDIR="$(get_fishcompdir)"
-	)
-
-	emake "${mymakeargs[@]}" install-data
+	emake DESTDIR="${D}" PREFIX="${EPREFIX}"/usr install-man
 }


             reply	other threads:[~2024-11-27 14:35 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-27 14:34 David Roman [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-11-21 10:47 [gentoo-commits] repo/proj/guru:master commit in: dev-util/find-work/ David Roman
2024-11-20 15:47 David Roman
2024-08-20 20:46 David Roman
2024-08-09 12:46 David Roman
2024-04-29 21:27 David Roman
2024-04-19 19:11 Julien Roy
2024-02-09  0:30 David Roman
2024-02-09  0:30 David Roman
2024-01-15 15:46 David Roman
2024-01-15 15:46 David Roman
2024-01-09 12:03 David Roman
2024-01-08  7:22 Viorel Munteanu
2024-01-07 23:46 David Roman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1732630486.d13007f37a5de2b08b43586adfe70f817867e9f0.davidroman@gentoo \
    --to=davidroman96@gmail.com \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox