X-Git-Url: http://git.madism.org/?p=apps%2Fmadmutt.git;a=blobdiff_plain;f=muttbug.sh.in;h=2f73ab227199f7656578081a9779a5716e6c9e08;hp=d3a135d79644f3b72be0742fd0dc07b069b96f4f;hb=8682670f5c23aca480236b8456aa8192b154a3e0;hpb=cf3b7c1d74544527da3f894bc732d696731a5cde diff --git a/muttbug.sh.in b/muttbug.sh.in index d3a135d..2f73ab2 100644 --- a/muttbug.sh.in +++ b/muttbug.sh.in @@ -5,12 +5,12 @@ # # -# $Id: muttbug.sh.in,v 3.6 2003/09/20 06:24:10 roessler Exp $ +# $Id: muttbug.sh.in,v 3.7 2005/01/09 15:35:51 roessler Exp $ # # # Copyright (c) 2000 Thomas Roessler -# +# Parts were written/modified by Nico Golde # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -24,10 +24,11 @@ # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA. +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +# USA. # -SUBMIT="submit@bugs.guug.de" +SUBMIT="mutt-ng-devel@lists.berlios.de" DEBIAN_SUBMIT="submit@bugs.debian.org" prefix=@prefix@ @@ -98,7 +99,7 @@ trap "rm -r -f ${SCRATCH} ; trap '' 0 ; exit" 0 1 2 TEMPLATE=${SCRATCH}/template.txt if test -z "$EMAIL" ; then - EMAIL="`mutt -Q from 2> /dev/null | sed -e 's/^from=.\(.*\).$/\1/'`" + EMAIL="`muttng -Q from 2> /dev/null | sed -e 's/^from=.\(.*\).$/\1/'`" fi echo "Please enter your e-mail address [$EMAIL]:" @@ -146,27 +147,28 @@ case "$severity" in 4|[Cc]) severity=critical ;; *) severity=normal ;; esac - -if test -x $DEBUGGER ; then - test -f core && CORE=core - echo "If mutt has crashed, it may have saved some program state in" - echo "a file named core. We can include this information with the bug" - echo "report if you wish so." - echo "Do you want to include information gathered from a core file?" - echo "If yes, please enter the path - otherwise just say no: [$CORE]" - echo $n "> $c" - read _CORE - test "$_CORE" && CORE="$_CORE" +if [ "$severity" != "wishlist" ] ; then + if test -x $DEBUGGER ; then + test -f core && CORE=core + echo "If Mutt-ng has crashed, it may have saved some program state in" + echo "a file named core. We can include this information with the bug" + echo "report if you wish so." + echo "Do you want to include information gathered from a core file?" + echo "If yes, please enter the path - otherwise just say no: [$CORE]" + echo $n "> $c" + read _CORE + test "$_CORE" && CORE="$_CORE" + fi fi -echo $n "Do you want to include your personal mutt configuration files? [Y|n] $c" +echo $n "Do you want to include your personal Mutt-ng configuration files? [Y|n] $c" read personal case "$personal" in [nN]*) personal=no ;; *) personal=yes ;; esac -echo $n "Do you want to include your system's global mutt configuration file? [Y|n] $c" +echo $n "Do you want to include your system's global Mutt-ng configuration file? [Y|n] $c" read global case "$global" in [nN]*) global=no ;; @@ -175,33 +177,39 @@ esac if test -f /etc/debian_version ; then DEBIAN=yes - echo $n "Checking whether mutt has been installed as a package... $c" - DEBIANVERSION="`dpkg -l mutt | grep '^[ih]' | awk '{print $3}'`" 2> /dev/null + echo $n "Checking whether Mutt-ng has been installed as a Debian package... $c" + DEBIANVERSION="`dpkg -l muttng | grep '^[ih]' | awk '{print $3}'`" 2> /dev/null if test "$DEBIANVERSION" ; then DPKG=yes else DPKG=no unset DEBIANVERSION fi - echo "$DPKG" - echo $n "File this bug with Debian? [Y|n] $c" - read DPKG - case "$DPKG" in - [nN]) DPKG=no ;; - *) DPKG=yes ;; - esac + if [ "$DPKG" = "yes" ] ; then + echo "$DPKG" + echo $n "File this bug with Debian? [Y|n] $c" + read DPKG + case "$DPKG" in + [nN]) DPKG=no ;; + *) DPKG=yes ;; + esac + fi else DEBIAN=no DPKG=no fi - -if rpm -q mutt > /dev/null 2> /dev/null ; then - echo "Mutt seems to come from an RPM package." - RPMVERSION="`rpm -q mutt`" - RPMPACKAGER="`rpm -q -i mutt | sed -n -e 's/^Packager *: *//p'`" +if [ "$DPKG" = "yes" ] ; then + echo "" + echo "Use reportbug muttng to report the bug to the debian bug tracking system..." + exit +fi +if rpm -q mutt-ng > /dev/null 2> /dev/null ; then + echo "Mutt-ng seems to come from an RPM package." + RPMVERSION="`rpm -q mutt-ng`" + RPMPACKAGER="`rpm -q -i mutt-ng | sed -n -e 's/^Packager *: *//p'`" fi -MUTTVERSION="`mutt -v | awk '{print $2; exit; }'`" +MUTTVERSION="`muttng -v | awk '{print $2 $3; exit; }'`" test "$DPKG" = "yes" && SUBMIT="$SUBMIT, $DEBIAN_SUBMIT" exec > ${TEMPLATE} @@ -210,11 +218,11 @@ test "$EMAIL" && echo "From: $EMAIL" test "$REPLYTO" && echo "Reply-To: $REPLYTO" test "$ORGANIZATION" && echo "Organization: $ORGANIZATION" -echo "Subject: mutt-$MUTTVERSION: $SUBJECT" +echo "Subject: Mutt-ng $MUTTVERSION: $SUBJECT" echo "To: $SUBMIT" test "$EMAIL" && echo "Bcc: ${EMAIL}" echo -echo "Package: mutt" +echo "Package: mutt-ng" echo "Version: ${DEBIANVERSION-${RPMVERSION-$MUTTVERSION}}" echo "Severity: $severity" echo @@ -225,7 +233,7 @@ echo if test "$DEBIAN" = "yes" ; then echo "Obtaining Debian-specific information..." > /dev/tty - bug -p -s dummy mutt < /dev/null 2> /dev/null | \ + bug -p -s dummy muttng < /dev/null 2> /dev/null | \ sed -n -e "/^-- System Information/,/^---/p" | \ grep -v '^---' else @@ -251,11 +259,10 @@ echo echo "- CFLAGS" echo @CFLAGS@ - echo -echo "-- Mutt Version Information" +echo "-- Mutt-ng Version Information" echo -mutt -v +muttng -v if test "$CORE" && test -f "$CORE" ; then echo