#!/bin/sh # The config file for this contained things like: # pils ssh azz@pils.us-lot.org # This script (when invoked as machines-update) created a load of links to # itself for all the named machines in my bin directory, so I could just type # "pils" to log in to pils. It was more useful when I had machines that needed # Kerberos login. I just use ssh's config file for this these days. BINDIR=$HOME/bin MACHINESRC=$HOME/.machinesrc machine=`basename $0` if [ "$machine" = "machines-update" ] ; then while read name command ; do if [ "$name" != "" -a "$name" != "#" ] ; then ln -sf machines-login $BINDIR/$name fi done <$MACHINESRC exit 0 fi while read <&3 name command ; do if [ "$name" = "$machine" ] ; then exec 3<&- exec $command "$@" fi done 3<$MACHINESRC exit 20