From 76ee162ea1c6efc0cea1014f31affb1697be6abb Mon Sep 17 00:00:00 2001 From: Frank Terbeck Date: Tue, 24 Jul 2012 22:34:03 +0200 Subject: [PATCH] Only define vim() if vim is available Signed-off-by: Frank Terbeck --- etc/zsh/zshrc | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/etc/zsh/zshrc b/etc/zsh/zshrc index 3b65a09..2d5c189 100644 --- a/etc/zsh/zshrc +++ b/etc/zsh/zshrc @@ -2156,9 +2156,11 @@ deswap() { # VIM_OPTIONS=( -p ) # This will cause vim to send every file given on the # commandline to be send to it's own tab (needs vim7). -vim() { - VIM_PLEASE_SET_TITLE='yes' command vim ${VIM_OPTIONS} "$@" -} +if check_com vim; then + vim() { + VIM_PLEASE_SET_TITLE='yes' command vim ${VIM_OPTIONS} "$@" + } +fi # make a backup of a file bk() { -- 2.1.4