#!/bin/sh

#please paul leave it this way for todays data taking
#our gui has to be debugged but we have beam now, sorry

#shutDown
#sleep 200

if [ -r runner.lock ]; then

 kill -TERM `cat runner.lock`
 sleep 3
 kill -KILL `cat runner.lock`
 sleep 1
 rm runner.lock

fi

if [ -r sktHstGeneric.lock ]; then

 kill -KILL `cat sktHstGeneric.lock`
 sleep 1
 rm sktHstGeneric.lock

fi

if [ -r sktReadout.lock ]; then

 kill -KILL `cat sktReadout.lock`
 sleep 1
 rm sktReadout.lock

fi

if [ -r sktTrgReadout.lock ]; then

 kill -KILL `cat sktTrgReadout.lock`
 sleep 1
 rm sktTrgReadout.lock

fi

if [ -r sktAhcReadout.lock ]; then

 kill -KILL `cat sktAhcReadout.lock`
 sleep 1
 rm sktAhcReadout.lock

fi

if [ -r sktEmcReadout.lock ]; then

 kill -KILL `cat sktEmcReadout.lock`
 sleep 1
 rm sktEmcReadout.lock

fi
