#!/bin/sh USRXMODMAP="$HOME/.Xmodmap" if [ -x /usr/bin/xmodmap -a -f $USRXMODMAP ]; then /usr/bin/xmodmap $USRXMODMAP || true fi /usr/bin/fvwm2 -f /etc/nx.fvwm2 & /usr/NX/bin/nxclient WAITPID=`pgrep -s 0 nxssh` while `ps -eo pid | grep -q $WAITPID`; do sleep 5 done pkill -s 0 fvwm2