synergyクライアント起動時にサーバをコンピュータ名で指定する
#!/bin/sh SYNERGYC=/usr/bin/synergyc SCREEN_NAME=`hostname -s` lssmb() { MASTER=`nmblookup -M - | grep -v "^querying" | awk '{ print $1 }'` smbclient -N -L $MASTER | perl -ne'print if /^\tServer/../^$/' } if [ -z $1 ]; then echo "$0: No host specified." echo "You can choose one from these:" lssmb; exit; fi IP=`nmblookup $1 | grep -v "^querying" | awk '{ print $1 }'` $SYNERGYC -n $SCREEN_NAME $IP && echo "Synergyc started."