#!/bin/sh 
# 
# runparts.sh by macsat@macsat.com 
# intended for use with cron 
#
# based on rc.unslung by unslung guys :-)
#
if [ -z "$1" ]
then 
echo "Usage : $0 "
fi

RUNDIR=$1"/*"

for i in $RUNDIR ;do

# Ignore dangling symlinks (if any).
[ ! -f "$i" ] && continue

case "$i" in
*.sh)
# Source shell script for speed.
(
trap - INT QUIT TSTP
set start
. $i
)
;;
*)
# No sh extension, so fork subprocess.
$i start
;;
esac
done