#!/bin/sh
### $usepop/INSTALL/CREATE_SCRIPTS
###
### create startup scripts for poplog located at $1
### Assumes $poplocal has already been set
### This is normally run in the startup directory by installation
### scripts
## Aaron Sloman
## 17 Jan 2005

# Run this in INSTALL directory

echo "making script for sh ksh and bash users"
rm -f $usepop/bin/poplog.sh
cat poplog1.sh   > $usepop/bin/poplog.sh
echo "poplogroot=$1"     >> $usepop/bin/poplog.sh
echo "export poplogroot" >> $usepop/bin/poplog.sh
cat poplog2.sh   >> $usepop/bin/poplog.sh

chmod 755 $usepop/bin/poplog.sh

echo ""
echo ""

echo "making script for csh and tcsh users"
rm -f $usepop/bin/poplog
cat poplog1   > $usepop/bin/poplog
echo "setenv poplogroot $1"     >> $usepop/bin/poplog
cat poplog2   >> $usepop/bin/poplog

chmod 755 $usepop/bin/poplog
