From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 6FAC515808C for ; Sun, 20 Feb 2022 19:02:09 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id A4DE4E085A; Sun, 20 Feb 2022 19:02:08 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 8B323E085A for ; Sun, 20 Feb 2022 19:02:08 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 60981343862 for ; Sun, 20 Feb 2022 19:02:07 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id E7F8A2EB for ; Sun, 20 Feb 2022 19:02:05 +0000 (UTC) From: "Anna Vyalkova" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Anna Vyalkova" Message-ID: <1645383708.5c2ef748c6d6d35d806db28fd9550e6b940312b5.cybertailor@gentoo> Subject: [gentoo-commits] repo/proj/guru:dev commit in: net-news/sfeed/ X-VCS-Repository: repo/proj/guru X-VCS-Files: net-news/sfeed/sfeed-1.2.ebuild X-VCS-Directories: net-news/sfeed/ X-VCS-Committer: cybertailor X-VCS-Committer-Name: Anna Vyalkova X-VCS-Revision: 5c2ef748c6d6d35d806db28fd9550e6b940312b5 X-VCS-Branch: dev Date: Sun, 20 Feb 2022 19:02:05 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 358da51a-fcf6-41f3-a467-8f9f247b58e2 X-Archives-Hash: 8bbab2e1b9d07a233f454a77f857d820 commit: 5c2ef748c6d6d35d806db28fd9550e6b940312b5 Author: Anna (cybertailor) Vyalkova sysrq in> AuthorDate: Sat Feb 19 17:30:03 2022 +0000 Commit: Anna Vyalkova sysrq in> CommitDate: Sun Feb 20 19:01:48 2022 +0000 URL: https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=5c2ef748 net-news/sfeed: more flexible theme handling Signed-off-by: Anna (cybertailor) Vyalkova sysrq.in> net-news/sfeed/sfeed-1.2.ebuild | 37 ++++++++++++------------------------- 1 file changed, 12 insertions(+), 25 deletions(-) diff --git a/net-news/sfeed/sfeed-1.2.ebuild b/net-news/sfeed/sfeed-1.2.ebuild index 64d5fe0fb..ea650ce68 100644 --- a/net-news/sfeed/sfeed-1.2.ebuild +++ b/net-news/sfeed/sfeed-1.2.ebuild @@ -12,21 +12,16 @@ if [[ ${PV} == 9999 ]]; then inherit git-r3 EGIT_REPO_URI="git://git.codemadness.org/sfeed" else - SRC_URI="https://www.codemadness.org/releases/sfeed/sfeed-${PV}.tar.gz" + SRC_URI="https://www.codemadness.org/releases/${PN}/${P}.tar.gz" KEYWORDS="~amd64" fi LICENSE="ISC" SLOT="0" -IUSE=" - +ncurses - +theme-mono - theme-mono-highlight - theme-newsboat - theme-templeos -" -REQUIRED_USE="ncurses? ( ^^ ( theme-mono theme-mono-highlight theme-newsboat theme-templeos ) )" +THEMES=( mono{,-highlight} newsboat templeos ) +IUSE="+ncurses +$(printf "theme-%s " ${THEMES[@]})" +REQUIRED_USE="ncurses? ( ^^ ( $(printf "theme-%s " ${THEMES[@]}) ) )" DEPEND="ncurses? ( sys-libs/ncurses )" RDEPEND="${DEPEND} @@ -35,23 +30,15 @@ RDEPEND="${DEPEND} BDEPEND="virtual/pkgconfig" src_configure() { - if use theme-mono ; then - SFEED_THEME="mono" - elif use theme-mono-highlight ; then - SFEED_THEME="mono_highlight" - elif use theme-newsboat ; then - SFEED_THEME="newsboat" - elif use theme-templeos ; then - SFEED_THEME="templeos" - fi + for name in "${THEMES[@]}"; do + if use theme-${name}; then + SFEED_THEME="${name//-/_}" + fi + done - if use ncurses ; then - SFEED_CURSES="sfeed_curses" - else - SFEED_CURSES="" - fi + use ncurses && SFEED_CURSES="sfeed_curses" - restore_config themes/mono.h themes/mono_highlight.h themes/newsboat.h themes/templeos.h + restore_config $(printf "themes/%s.h " ${THEMES[@]//-/_}) } src_compile() { @@ -72,5 +59,5 @@ src_install() { einstalldocs - save_config themes/mono.h themes/mono_highlight.h themes/newsboat.h themes/templeos.h + save_config $(printf "themes/%s.h " ${THEMES[@]//-/_}) }