#!/bin/bash # # file: /usr/local/bin/xemacs # purpose: wrapper for xemacs # created: pasha sep 20 2007 # modified: pasha mar 4 2016 # modification: do not check for user # if [ "$1" == "--new" ]; then shift 1 exec /usr/bin/xemacs $@ & exit fi #if [ "`pidof $XEMACS`" == "" ]; then # in cygwin, 'pgrep -f /usr/bin/xemacs-21.4.24' doesn't work #if [ "`pgrep -u $USER xemacs`" == "" ]; then if [ "`pgrep xemacs`" == "" ]; then # xemacs is not running exec /usr/bin/xemacs $@ & else # xemacs is running; # assuming that gnuserv is running at the xemacs side exec gnuclient -q -nw $@ fi # end of xemacs