view src/which.sh @ 3997:c83cd3d01128 v7.3.753

updated for version 7.3.753 Problem: When there is a QuitPre autocommand using ":q" twice does not work for exiting when there are more files to edit. Solution: Do not decrement quitmore in an autocommand. (Techlive Zheng)
author Bram Moolenaar <bram@vim.org>
date Wed, 05 Dec 2012 19:13:18 +0100
parents 3fc0f57ecb91
children
line wrap: on
line source

#! /bin/sh
#
# which.sh -- find where an executable is located.  It's here because the
# "which" command is not supported everywhere.  Used by Makefile.

IFS=":"
for ac_dir in $PATH; do
	if test -f "$ac_dir/$1"; then
		echo "$ac_dir/$1"
		break
	fi
done