From ec6c924f8791926693a515524b27eb805be50f63 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sat, 21 Nov 2009 23:20:29 +0100 Subject: Remove check_com function --- etc/functions/check_com | 32 -------------------------------- 1 file changed, 32 deletions(-) delete mode 100644 etc/functions/check_com (limited to 'etc/functions/check_com') diff --git a/etc/functions/check_com b/etc/functions/check_com deleted file mode 100644 index 21de466..0000000 --- a/etc/functions/check_com +++ /dev/null @@ -1,32 +0,0 @@ -## vim:ft=zsh -## Check for a command/function -## Usage: check_com [-c] -## Taken from the grml zshrc - http://grml.org -local -i comonly - -if [[ ${1} == '-c' ]] ; then - (( comonly = 1 )) - shift -else - (( comonly = 0 )) -fi - -if (( ${#argv} != 1 )) ; then - printf 'usage: check_com [-c] \n' >&2 - return 1 -fi - -if (( comonly > 0 )) ; then - [[ -n ${commands[$1]} ]] && return 0 - return 1 -fi - -if [[ -n ${commands[$1]} ]] \ - || [[ -n ${functions[$1]} ]] \ - || [[ -n ${aliases[$1]} ]] \ - || [[ -n ${reswords[(r)$1]} ]] ; then - - return 0 -fi - -return 1 -- cgit v1.2.3