--- 2003-02-27-23/moz Thu Feb 27 23:52:20 2003 +++ latest/moz Fri Feb 28 17:28:42 2003 @@ -1,5 +1,5 @@ #!/bin/sh - ver="0.2.2b+.2003-02-27-22" + ver="0.2.2b+.2003022817" copy="2002, 2003" mail="PointedEars@gmx.de" mail_feedback="bug-moz@PointedEars.de" @@ -50,12 +50,12 @@ mail_feedback="bug-moz@PointedEars.de" # * `-i' opens a new MailNews window # * `-c' opens a new Compose window with empty `To:' field # * L10n: English and German (using macro function) - # * _XPG=1 for $( $command ) in `sh' (@IRIX 6.5) # * Send error messages to stderr # * Fixed function-in-statement-bug on `sh' (@IRIX) # * Support SysV compliant `ps' calls (@IRIX) # * If not running on first argument, wait for the process # [with `-remote ping()'] before passing on to the second argument + # * _XPG=1 for `$( `$command` )' and `$(( `$expression` ))' in `sh' (@IRIX 6.5) # * Cosmetics: # - Added status messages # - Bold-formatted title with changed tagline @@ -206,7 +206,7 @@ function msg_failed { function help { echo - echo "${extd}`basename $0`${norm} + echo "${extd}`basename "$1"`${norm} [${extd}-v${norm}] [${extd}-L${norm} LOCALE] [${extd}-M${norm} COMMAND] \ [ ( ${extd}-?${norm} | ${extd}--term${norm} | ${extd}--kill${norm} | \ ${extd}-l${norm} ) ] @@ -499,31 +499,30 @@ Bitte überprüfen Sie ihre Mozilla-Instal | $fold >&2 fi + _XPG=1 return $(( $result )) + _XPG=0 } - _XPG=1 echo " - ${extd}moz $ver -- $(L "Mozilla process manager" "Manager für \ - Mozilla-Prozesse")${norm} + ${extd}moz $ver -- "`L "Mozilla process manager" "Manager für \ + Mozilla-Prozesse"`"${norm} Copyright (C) $copy Thomas Lahn <$mail> - $(L "Distributed under the terms of the" \ - "Veröffentlicht unter den Bedingungen der") GNU General Public License (GPL), - $(L "see COPYING file or http://www.fsf.org/copyleft/gpl.html for details." \ + "`L "Distributed under the terms of the" \ + "Veröffentlicht unter den Bedingungen der"`" GNU General Public License (GPL), + "`L "see COPYING file or http://www.fsf.org/copyleft/gpl.html for details." \ "Details in Datei COPYING oder unter http://www.fsf.org/copyleft/gpl.html" \ - | $fold)" + | $fold` if [ -z "$1" ] || [ "$1" = "-?" ] || [ "$1" = "--help" ]; then help=1; test -n "$1" && shift fi - test $help -eq 1 && help + test $help -eq 1 && help "$0" - _XPG=1 - echo "$(L "Send suggestions and bug reports to" \ - "Senden Sie Vorschläge und Fehlerberichte an") <$mail_feedback> + echo `L "Send suggestions and bug reports to" \ + "Senden Sie Vorschläge und Fehlerberichte an"`" <$mail_feedback> " | $fold - _XPG=0 test $help -eq 1 && exit 255 @@ -597,10 +596,12 @@ fi # check for Mozilla chk=`which mozilla 2> /dev/null` if [ $? -ne 0 ]; then + _XPG=1 echo "`basename $0`: \ $(L "The \`mozilla' executable is required for this program." \ "Die ausführbare Datei \`mozilla' wird für dieses Programm benötigt.") " | $fold >&2 + _XPG=0 exit 255 fi @@ -648,7 +649,9 @@ while [ -n "$1" ]; do # check if the current user has Mozilla already run # AFAIK mozilla -remote "ping()" does not pay respect to different accounts + _XPG=1 chk=`ps -fu $(whoami) 2> /dev/null | grep mozilla-bin | grep -v grep` + _XPG=0 if [ -z "$chk" ]; then echo -n `L "Starting a new Mozilla process" \ "Starte einen neuen Mozilla-Prozess"` @@ -715,6 +718,7 @@ Bitte überprüfen Sie ihre Mozilla-Instal fi # checking for grep chk=`which grep 2> /dev/null` + _XPG=1 if [ $? -ne 0 ]; then echo "`basename $0`: \`grep' "\ $(L "not found. Cannot check for \`mailto:' URI." \ @@ -735,6 +739,7 @@ $(L "not found. Cannot handle \`mailto:' mailto=1 fi fi + _XPG=0 if [ $mailto -eq 0 ] && [ $inbox -eq 0 ] && [ $compose -eq 0 ]; then echo -n `L "Accessing URI" "Lade URI"`" " if [ -n "$1" ]; then