#!/bin/sh
PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin

##find a suitable terminal
TERMINAL=""
if [ "`which rxvt`" != "" ]; then
TERMINAL=rxvt
elif [ "`which urxvt`" != "" ]; then
TERMINAL=urxvt
elif [ "`which mrxvt`" != "" ]; then
TERMINAL=mrxvt
elif [ "`which aterm`" != "" ]; then
TERMINAL=aterm
elif [ "`which materm`" != "" ]; then
TERMINAL=materm
elif [ "`which xterm`" != "" ]; then
TERMINAL=xterm
elif [ "`which Eterm`" != "" ]; then
TERMINAL=Eterm
elif [ "`which sakura`" != "" ]; then
TERMINAL=sakura
elif [ "`which konsole`" != "" ]; then
TERMINAL=konsole
elif [ "`which gnome-terminal`" != "" ]; then
TERMINAL=gnome-terminal
elif [ "`which xfce4terminal`" != "" ]; then
TERMINAL=xfce4terminal
elif [ "`which xfce4term`" != "" ]; then
TERMINAL=xfce4term
elif [ "`which xfce4-term`" != "" ]; then
TERMINAL=xfce4-term
fi

$TERMINAL -e /usr/bin/sshd.sh