#! /bin/ksh

#
# Name        : ${HOME}/bin/SearchKsh93.ksh
#
# Version     : 1.0
#
# Author      : Gerard van Wageningen
#
# Description : Look for the ksh93 executable
#
# 1.0   First Version
#

\whence set_debug 1>/dev/null 2>&1 && eval $( set_debug ${0##*/} )

typeset i=''

for i in \
  "${HOME}/${UNAME}/ksh93" \
  "${HOME}/AIX/ksh93" \
  "${HOME}/Linux/ksh93" \
  "${HOME}/bin/ksh93" \
  'AIX/ksh93' \
  'bin/kshksh93' \
  '/bin/ksh93' \
  '/usr/bin/ksh93'
do
  if [[ -x "${i}" ]]
  then
    SHELL="${i}"
    exec "${i}" "$@"
  fi
done

print -u2 "Error: Can not find ksh93 executable, bailing out..."

exit 1

################# EOF #################
