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.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 773BF138359 for ; Sun, 19 Jul 2020 20:21:02 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 9EA2EE086D; Sun, 19 Jul 2020 20:21:01 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 827BEE086C for ; Sun, 19 Jul 2020 20:21:01 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id E146F34F29F for ; Sun, 19 Jul 2020 20:20:59 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 535A82A4 for ; Sun, 19 Jul 2020 20:20:58 +0000 (UTC) From: "Patrick McLean" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Patrick McLean" Message-ID: <1595187934.e1e4f5df30ab46a3787f4cdfb4a6092c2a3544d2.chutzpah@gentoo> Subject: [gentoo-commits] proj/eselect-python:master commit in: / X-VCS-Repository: proj/eselect-python X-VCS-Files: python.eselect.in X-VCS-Directories: / X-VCS-Committer: chutzpah X-VCS-Committer-Name: Patrick McLean X-VCS-Revision: e1e4f5df30ab46a3787f4cdfb4a6092c2a3544d2 X-VCS-Branch: master Date: Sun, 19 Jul 2020 20:20:58 +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: 9f09f638-3533-4574-b20c-8a53278610d0 X-Archives-Hash: 35ff29a8102c865ccae8e8d873fe795d commit: e1e4f5df30ab46a3787f4cdfb4a6092c2a3544d2 Author: Patrick McLean gentoo org> AuthorDate: Sun Jul 19 19:26:39 2020 +0000 Commit: Patrick McLean gentoo org> CommitDate: Sun Jul 19 19:45:34 2020 +0000 URL: https://gitweb.gentoo.org/proj/eselect-python.git/commit/?id=e1e4f5df Handle zstd man pages, use .so format rather than a symlink Handling removing .zst{,d} compressed man pages. Move to using .so reference rather than a symlink to have "man python" point to the right implementation. Signed-off-by: Patrick McLean gentoo.org> python.eselect.in | 19 +++---------------- 1 file changed, 3 insertions(+), 16 deletions(-) diff --git a/python.eselect.in b/python.eselect.in index 98b8cc9..5fa0fb1 100644 --- a/python.eselect.in +++ b/python.eselect.in @@ -111,23 +111,10 @@ write_preferences() { # Set a man page symlink set_man_symlink() { - local target=${1} x suffix - - rm -f "${MAN_PATH}"/python.1{,.gz,.bz2,.lzma,.xz,.lz} || die - - for x in .1{,.gz,.bz2,.lzma,.xz,.lz}; do - if [[ -e "${MAN_PATH}/${target}${x}" ]]; then - suffix=${x} - break - fi - done - - if [[ ! ${suffix} ]]; then - echo "Couldn't find a man page for ${target}; skipping." 1>&2 - return 1 - fi + local target=${1} - ln -nfs "${target}${suffix}" "${MAN_PATH}/python${suffix}" || die + rm -f "${MAN_PATH}"/python.1{,.{gz,bz2,lzma,xz,lz,zst{,d}}} || die + echo ".so ${target}.1" > "${MAN_PATH}"/python.1 || die } # Set OSX framework symlinks