#!/bin/bash
# Local things

function testexegcp {
  [ -r $1 ] || return
  egrep $2 $1 >/dev/null || return
  [ -d $3 ] && cp -p $1 $3
}

PATH=/sbin:/bin:/usr/sbin:/usr/bin
echo $0

case "$1" in
    start)
	testexegcp /afs/mcc/common/etc/ssh/ssh_known_hosts nevis.mc.man.ac.uk /etc/ssh/
	testexegcp /afs/mcc/common/etc/CellServDB nevis.mc.man.ac.uk /etc/openafs/
	testexegcp /afs/mcc/common/etc/ThisCell mcc.ac.gb /etc/openafs/
	testexegcp /afs/mcc/common/etc/krb5.conf nevis.mc.man.ac.uk /etc/
	;;
    stop)
	;;
    *)
	echo "Usage: $0 {start|stop}"
	exit 1
	;;
esac
exit 0
