From: Chris Koeritz Date: Fri, 12 Apr 2013 20:51:50 +0000 (-0400) Subject: added a few options for EDITOR X-Git-Tag: 2.140.90~1021 X-Git-Url: https://feistymeow.org/gitweb/?a=commitdiff_plain;h=da333cc52006dc1ea40741b894347e8dc30aa45c;p=feisty_meow.git added a few options for EDITOR --- diff --git a/customizing/fred/fred_variables.sh b/customizing/fred/fred_variables.sh index feb32584..5ca2c338 100644 --- a/customizing/fred/fred_variables.sh +++ b/customizing/fred/fred_variables.sh @@ -41,6 +41,15 @@ if [ -z "$NETHACKOPTIONS" ]; then # editor and other mixed settings... export EDITOR="$(which vim)" + if [ -z "$EDITOR" ]; then + EDITOR="$(which vi)" + if [ -z "$EDITOR" ]; then + EDITOR="$(which emacs)" + if [ -z "$EDITOR" ]; then + echo "Cannot find a friendly editor." + fi + fi + fi export VISUAL="$EDITOR" # the editors for revision control must wait while document is edited, # so gvim and others launched to x window are not appropriate.