--- ray/src/util/tradinstall.csh 1995/09/13 16:14:12 2.1 +++ ray/src/util/tradinstall.csh 1995/11/07 09:58:43 2.3 @@ -1,11 +1,11 @@ -#!/bin/csh -f +#!/bin/csh -fe # SCCSid "$SunId$ LBL" # Install correct version of trad for wish or wish4.0 # set instdir = $1 set libdir = $2 -set TLIBFILES = ( *.tcl *.hlp trad.icon tclIndex ) +set TLIBFILES = ( *[a-z].tcl *.hlp trad.icon tclIndex ) set TDIFFS = (`ls | sed -n 's/3\.6\.tcl$//p'`) @@ -18,7 +18,7 @@ end if (! $?wishcom) then foreach d ($path) if (-x $d/wish) then - set wishcom = $d/wish + set wishcom = "$d/wish -f" break endif end @@ -31,15 +31,17 @@ endif echo "Installing trad using $wishcom" -sed -e "1s|/usr/local/bin/wish|$wishcom|" \ +sed -e "1s|/usr/local/bin/wish4\.0|$wishcom|" \ -e "s|^set radlib .*|set radlib $libdir|" trad.wsh > $instdir/trad -if ($status) exit 1 chmod 755 $instdir/trad +if (! -d $libdir) then + mkdir $libdir +endif (cd $libdir ; rm -f $TLIBFILES) cp $TLIBFILES $libdir if ($?oldwish) then foreach i ($TDIFFS) - (cd $libdir ; rm -f $i.tcl) + rm -f $libdir/$i.tcl cp ${i}3.6.tcl $libdir/$i.tcl end endif