From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1SR4EF-0007Ea-Ej for garchives@archives.gentoo.org; Sun, 06 May 2012 16:22:36 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 2E21DE08A0; Sun, 6 May 2012 16:13:23 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 8BD03E09CC for ; Sun, 6 May 2012 16:07:16 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id F0F2F1B405C for ; Sun, 6 May 2012 16:07:10 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id B75E9E542E for ; Sun, 6 May 2012 16:07:09 +0000 (UTC) From: "Sebastian Pipping" To: gentoo-commits@lists.gentoo.org Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sebastian Pipping" Message-ID: <1174999067.202509f38e753661418f6a299f1d324d58a92b42.sping@gentoo> Subject: [gentoo-commits] proj/emacs-tools:backups/emacs-common-gentoo@1233 commit in: / X-VCS-Repository: proj/emacs-tools X-VCS-Files: ChangeLog emacs.eselect X-VCS-Directories: / X-VCS-Committer: sping X-VCS-Committer-Name: Sebastian Pipping X-VCS-Revision: 202509f38e753661418f6a299f1d324d58a92b42 X-VCS-Branch: backups/emacs-common-gentoo@1233 Date: Sun, 6 May 2012 16:07:09 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: quoted-printable X-Archives-Salt: a2acab23-84a4-4ae1-bf68-d5b55e665796 X-Archives-Hash: 67e5a68ab48866e0a306b4aea63a66b5 commit: 202509f38e753661418f6a299f1d324d58a92b42 Author: Ulrich M=C3=BCller gentoo org> AuthorDate: Tue Mar 27 12:37:47 2007 +0000 Commit: Sebastian Pipping gentoo org> CommitDate: Tue Mar 27 12:37:47 2007 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=3Dproj/emacs-tools.g= it;a=3Dcommit;h=3D202509f3 Brought do_set and do_update more in line. svn path=3D/emacs-extra/eselect-emacs/; revision=3D179 --- ChangeLog | 1 + emacs.eselect | 32 +++++++++++--------------------- 2 files changed, 12 insertions(+), 21 deletions(-) diff --git a/ChangeLog b/ChangeLog index 2b17af6..db69dc0 100644 --- a/ChangeLog +++ b/ChangeLog @@ -49,3 +49,4 @@ Version 0.5 (24 Mar 2007) Removed -n option in emacsclient.desktop. 27 Mar 2007 Call env.eselect to update the environment from env.d files. + Brought do_set and do_update more in line. diff --git a/emacs.eselect b/emacs.eselect index 6ff6fd9..fee497c 100644 --- a/emacs.eselect +++ b/emacs.eselect @@ -176,25 +176,16 @@ describe_set_parameters() { } =20 do_set() { - if [[ -z "${1}" ]]; then - die -q "You didn't tell me what to set the symlink to" - - elif [[ -n "${2}" ]]; then - die -q "Too many parameters" - - elif [[ -L "${ROOT}/usr/bin/emacs" ]]; then - if ! remove_symlinks; then - die -q "Couldn't remove existing symlink" - elif ! set_symlinks "${1}"; then - die -q "Couldn't set a new symlink" - fi + [[ -z "${1}" ]] && die -q "You didn't tell me what to set the symlink t= o" + [[ -n "${2}" ]] && die -q "Too many parameters" =20 + if [[ -L "${ROOT}/usr/bin/emacs" ]]; then + remove_symlinks || die -q "Couldn't remove existing symlink" elif [[ -e "${ROOT}/usr/bin/emacs" ]]; then die -q "Sorry, ${ROOT}/usr/bin/emacs confuses me" - - else - set_symlinks "${1}" || die -q "Couldn't set a new symlink" fi + + set_symlinks "${1}" || die -q "Couldn't set a new symlink" } =20 ### update action ### @@ -212,12 +203,11 @@ do_update() { die -q "Usage error" =20 if [[ -L "${ROOT}/usr/bin/emacs" ]]; then - [[ ${1} =3D=3D "--if-unset" && - -e "$(canonicalise ${ROOT}/usr/bin/emacs)" ]] && return - remove_symlinks || die -q "Couldn't remove existing link" - fi - if [[ -e "${ROOT}/usr/bin/emacs" ]]; then - die -q "Couldn't set a new symlink" + [[ ${1} =3D=3D "--if-unset" \ + && -e "$(canonicalise ${ROOT}/usr/bin/emacs)" ]] && return + remove_symlinks || die -q "Couldn't remove existing symlink" + elif [[ -e "${ROOT}/usr/bin/emacs" ]]; then + die -q "Sorry, ${ROOT}/usr/bin/emacs confuses me" fi =20 local targets=3D( $(find_targets) ) From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1SR4Bp-0006jI-HF for garchives@archives.gentoo.org; Sun, 06 May 2012 16:20:07 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id EF626E09FF; Sun, 6 May 2012 16:10:20 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id D9421E09BE for ; Sun, 6 May 2012 16:07:07 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 47A481B405F for ; Sun, 6 May 2012 16:07:07 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id 2528EE5432 for ; Sun, 6 May 2012 16:07:05 +0000 (UTC) From: "Sebastian Pipping" To: gentoo-commits@lists.gentoo.org Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sebastian Pipping" Message-ID: <1174999067.202509f38e753661418f6a299f1d324d58a92b42.sping@gentoo> Subject: [gentoo-commits] proj/emacs-tools:backups/emacs-common-gentoo@1030 commit in: / X-VCS-Repository: proj/emacs-tools X-VCS-Files: ChangeLog emacs.eselect X-VCS-Directories: / X-VCS-Committer: sping X-VCS-Committer-Name: Sebastian Pipping X-VCS-Revision: 202509f38e753661418f6a299f1d324d58a92b42 X-VCS-Branch: backups/emacs-common-gentoo@1030 Date: Sun, 6 May 2012 16:07: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 Content-Transfer-Encoding: quoted-printable X-Archives-Salt: e5a28aa1-e82b-420b-b805-061d42193431 X-Archives-Hash: a073a276b353b102d0199b34cb1bb31b Message-ID: <20120506160705._IG0LCDd3l0SNvPPQGrGCeaVdIEcI2P8G4imXt18cEY@z> commit: 202509f38e753661418f6a299f1d324d58a92b42 Author: Ulrich M=C3=BCller gentoo org> AuthorDate: Tue Mar 27 12:37:47 2007 +0000 Commit: Sebastian Pipping gentoo org> CommitDate: Tue Mar 27 12:37:47 2007 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=3Dproj/emacs-tools.g= it;a=3Dcommit;h=3D202509f3 Brought do_set and do_update more in line. svn path=3D/emacs-extra/eselect-emacs/; revision=3D179 --- ChangeLog | 1 + emacs.eselect | 32 +++++++++++--------------------- 2 files changed, 12 insertions(+), 21 deletions(-) diff --git a/ChangeLog b/ChangeLog index 2b17af6..db69dc0 100644 --- a/ChangeLog +++ b/ChangeLog @@ -49,3 +49,4 @@ Version 0.5 (24 Mar 2007) Removed -n option in emacsclient.desktop. 27 Mar 2007 Call env.eselect to update the environment from env.d files. + Brought do_set and do_update more in line. diff --git a/emacs.eselect b/emacs.eselect index 6ff6fd9..fee497c 100644 --- a/emacs.eselect +++ b/emacs.eselect @@ -176,25 +176,16 @@ describe_set_parameters() { } =20 do_set() { - if [[ -z "${1}" ]]; then - die -q "You didn't tell me what to set the symlink to" - - elif [[ -n "${2}" ]]; then - die -q "Too many parameters" - - elif [[ -L "${ROOT}/usr/bin/emacs" ]]; then - if ! remove_symlinks; then - die -q "Couldn't remove existing symlink" - elif ! set_symlinks "${1}"; then - die -q "Couldn't set a new symlink" - fi + [[ -z "${1}" ]] && die -q "You didn't tell me what to set the symlink t= o" + [[ -n "${2}" ]] && die -q "Too many parameters" =20 + if [[ -L "${ROOT}/usr/bin/emacs" ]]; then + remove_symlinks || die -q "Couldn't remove existing symlink" elif [[ -e "${ROOT}/usr/bin/emacs" ]]; then die -q "Sorry, ${ROOT}/usr/bin/emacs confuses me" - - else - set_symlinks "${1}" || die -q "Couldn't set a new symlink" fi + + set_symlinks "${1}" || die -q "Couldn't set a new symlink" } =20 ### update action ### @@ -212,12 +203,11 @@ do_update() { die -q "Usage error" =20 if [[ -L "${ROOT}/usr/bin/emacs" ]]; then - [[ ${1} =3D=3D "--if-unset" && - -e "$(canonicalise ${ROOT}/usr/bin/emacs)" ]] && return - remove_symlinks || die -q "Couldn't remove existing link" - fi - if [[ -e "${ROOT}/usr/bin/emacs" ]]; then - die -q "Couldn't set a new symlink" + [[ ${1} =3D=3D "--if-unset" \ + && -e "$(canonicalise ${ROOT}/usr/bin/emacs)" ]] && return + remove_symlinks || die -q "Couldn't remove existing symlink" + elif [[ -e "${ROOT}/usr/bin/emacs" ]]; then + die -q "Sorry, ${ROOT}/usr/bin/emacs confuses me" fi =20 local targets=3D( $(find_targets) )