diff options
Diffstat (limited to 'ctct.in')
-rw-r--r-- | ctct.in | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -26,7 +26,7 @@ sysconfdir="@sysconfdir_expanded@" user_config_file="@default_user_config_file@" datadir="@default_datadir@" fallback_editor=("@default_fallback_editor@") -default_editor=() # none - use $EDITOR +default_editor=() # none - use $VISUAL / $EDITOR input_program=("@default_input_program@") output_program=("@default_output_program@") visual_program=("@default_visual_program@") @@ -316,7 +316,10 @@ function edit_contact() if test -n "${default_editor[*]}" then editor=( "${default_editor[@]}" ) - elif test -n "$EDITOR" && which "${EDITOR% *}" >/dev/null 2>&1 + elif test -n "$VISUAL" + then + editor=( $VISUAL ) + elif test -n "$EDITOR" then editor=( $EDITOR ) else |