From 940c3c3e2f2e30d63a58be1fd8c50c90a7d00100 Mon Sep 17 00:00:00 2001 From: Scott Wallace Date: Wed, 22 Jun 2016 11:59:43 +0100 Subject: [PATCH] Use vim, when possible. --- .bashrc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.bashrc b/.bashrc index c2b3a1d..8720fe0 100755 --- a/.bashrc +++ b/.bashrc @@ -40,8 +40,8 @@ getkey() { #-------------------------------------------------------------------------------- # The best editor #-------------------------------------------------------------------------------- -alias vi=vim -export EDITOR=vim +[[ -x $(which vim 2>/dev/null) ]] && alias vi=vim +export EDITOR=vi #-------------------------------------------------------------------------------- #--------------------------------------------------------------------------------