#!/bin/csh
# ---------- connect to CONTEL DUATS and save session
# by Eric Myers, (myers@landau.ph.utexas.edu)   4 March 1991
# with suggestions by Barney Lum (barney@sol.usc.edu)
# version 1.3
#
echo " "
set LOG=duat.log
if ( $#argv > 0 ) then
  set LOG=$1
endif
# If you have trouble with the date command below just remove or modify
echo "NOTE: Current Zulu Time:  " `date -u "+%T"`
echo " "
echo telnet duat.contel.com 
telnet duat.contel.com | tee duat.$$
# ---------- get rid of "--More--" at begining of a line and ^M at end 
grep -v "^--More--"  duat.$$ | tr -d "\015"  > $LOG
rm duat.$$
echo "Session saved in the file $LOG"
exit 0