view src/which.sh @ 14383:8846b8344430 v8.1.0206

patch 8.1.0206: duplicate test function name commit https://github.com/vim/vim/commit/cd96eef3a869557bd3d2d4497861d87cb525db06 Author: Bram Moolenaar <Bram@vim.org> Date: Mon Jul 23 04:49:23 2018 +0200 patch 8.1.0206: duplicate test function name Problem: Duplicate test function name. Solution: Rename both functions.
author Christian Brabandt <cb@256bit.org>
date Mon, 23 Jul 2018 05:00:05 +0200
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