From b09d2ef918f4d0c4ff6c0c6afcf69145b76c157e Mon Sep 17 00:00:00 2001 From: Michael Prokop Date: Sun, 18 Mar 2007 17:16:28 +0100 Subject: [PATCH] Check for mutt/muttng binaries in grml-mutt[ng]. Removed deprecated URL in grml-muttng --- debian/changelog | 2 ++ usr_bin/grml-mutt | 15 +++++++++------ usr_bin/grml-muttng | 14 +++++++++----- 3 files changed, 20 insertions(+), 11 deletions(-) diff --git a/debian/changelog b/debian/changelog index f6e58aa..af9035e 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,6 +1,8 @@ grml-scripts (0.9.31) unstable; urgency=low * Added xlockmore to suggests, added check for vlock in grml-lock. + * Check for mutt/muttng binaries in grml-mutt[ng]. Removed deprecated + URL in grml-muttng. -- Michael Prokop Sun, 18 Mar 2007 16:44:53 +0100 diff --git a/usr_bin/grml-mutt b/usr_bin/grml-mutt index 589573e..c09a1f9 100755 --- a/usr_bin/grml-mutt +++ b/usr_bin/grml-mutt @@ -4,11 +4,16 @@ # Authors: grml-team (grml.org), (c) Michael Prokop # Bug-Reports: see http://grml.org/bugs/ # License: This file is licensed under the GPL v2. -# Latest change: Son Apr 24 16:55:51 CEST 2005 [mika] +# Latest change: Son Mär 18 17:15:41 CET 2007 [mika] ################################################################################ PATH=${PATH:-'/bin/:/sbin/:/usr/local/bin:/usr/bin:/usr/sbin'} -PN=`basename "$0"` +PN=$(basename "$0") + +if [ -r /etc/grml/script-functions ] ; then + . /etc/grml/script-functions + check4progs dialog mutt || echo "Warning - mutt is not available. Continuing anyway.">&2 +fi writemuttrc() { cat > $MUTTRC << EOF @@ -382,17 +387,15 @@ case $retval in 0) writemuttrc && writecolors && \ dialog --stdout --title "$PN" --msgbox "Writing $MUTTRC was successful." 7 65 || \ - dialog --stdout --title "$PN" --msgbox "Error $?: writing $MUTTRC failed." 7 65 + { dialog --stdout --title "$PN" --msgbox "Error $?: writing $MUTTRC failed." 7 65 ; exit 1 ; } ;; -# *) exit 1 ;; esac else writemuttrc && writecolors && \ dialog --stdout --title "$PN" --msgbox "Writing $MUTTRC was successfull." 7 65 || \ - dialog --stdout --title "$PN" --msgbox "Error $?: writing $MUTTRC failed." 7 65 + { dialog --stdout --title "$PN" --msgbox "Error $?: writing $MUTTRC failed." 7 65 ; exit 1 ; } fi ;; -# *) exit 1 ;; esac dialog --stdout --title "$PN" --msgbox "Thanks for using $PN! diff --git a/usr_bin/grml-muttng b/usr_bin/grml-muttng index 55cc240..776c4c9 100755 --- a/usr_bin/grml-muttng +++ b/usr_bin/grml-muttng @@ -4,11 +4,16 @@ # Authors: grml-team (grml.org), (c) Michael Prokop # Bug-Reports: see http://grml.org/bugs/ # License: This file is licensed under the GPL v2. -# Latest change: Don Sep 21 20:00:07 CEST 2006 [mika] +# Latest change: Son Mär 18 17:15:16 CET 2007 [mika] ################################################################################ PATH=${PATH:-'/bin/:/sbin/:/usr/local/bin:/usr/bin:/usr/sbin'} -PN=`basename "$0"` +PN=$(basename "$0") + +if [ -r /etc/grml/script-functions ] ; then + . /etc/grml/script-functions + check4progs dialog muttng || echo "Warning - muttng is not available. Continuing anyway.">&2 +fi writemuttngrc() { cat > $MUTTRC << EOF @@ -410,13 +415,13 @@ case $retval in 0) writemuttngrc && writecolors && \ dialog --stdout --title "$PN" --msgbox "Writing $MUTTRC was successful." 7 65 || \ - dialog --stdout --title "$PN" --msgbox "Error $?: writing $MUTTRC failed." 7 65 + { dialog --stdout --title "$PN" --msgbox "Error $?: writing $MUTTRC failed." 7 65 ; exit 1 ; } ;; esac else writemuttngrc && writecolors && \ dialog --stdout --title "$PN" --msgbox "Writing $MUTTRC was successfull." 7 65 || \ - dialog --stdout --title "$PN" --msgbox "Error $?: writing $MUTTRC failed." 7 65 + { dialog --stdout --title "$PN" --msgbox "Error $?: writing $MUTTRC failed." 7 65 ; exit 1 ; } fi ;; esac @@ -431,7 +436,6 @@ Manuals: man 1 muttng Webpages: http://mutt-ng.berlios.de/ http://mutt-ng.supersized.org/ -http://www.strcat.de/muttng/pmwiki.php ####################################################### -- 2.1.4