#!/bin/sh # Copyright 2002 Rodrigo A. Real # This file is part of xcelmsg. # xcelmsg is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # xcelmsg is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # You should have received a copy of the GNU General Public License # along with xcelmsg; if not, write to the Free Software # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA CELMSG="/home/rcsd/cordeiro/Projetos/Claro/ClaroSMS" CMD="/work/cordeiro/Programas/Xdialog/bin/Xdialog --wrap --title xClaroSMS" # $CMD --msgbox "Enviador de mensagens para Celular da Claro Digital" 10 40 || exit 0 $CMD --inputbox "Seu nome" 10 40 2> tmp || exit 0 sender=`cat tmp` $CMD --inputbox "Numero do DDD" 10 40 2> tmp || exit 0 ddd=`cat tmp` $CMD --inputbox "Numero do Telefone" 10 40 2> tmp || exit 0 numero=`cat tmp` $CMD --max-input 150 --inputbox "Mensagem a enviar" 10 40 2> tmp || exit 0 msg=`cat tmp` echo "Confirma o envio da Mensagem?" >tmp echo "" >>tmp echo "De: $sender" >>tmp echo "Para: ($ddd) $numero" >>tmp echo "" >>tmp echo "Texto: $msg" >>tmp echo "" >>tmp confirma=`cat tmp` rm -f tmp $CMD --yesno "$confirma" 20 40 || { \ $CMD --msgbox "Envio cancelado" 10 40 exit 1 } $CELMSG $ddd $numero $sender \"$msg\" && { $CMD --msgbox "Mensagem enviada" 20 40 } exit