view src/which.sh @ 25403:9203b28ab453 v8.2.3238

patch 8.2.3238: Vim9: error message does not indicate the location Commit: https://github.com/vim/vim/commit/d47c39775b8d381005751b7b20da56412dafb5e4 Author: Bram Moolenaar <Bram@vim.org> Date: Wed Jul 28 20:52:13 2021 +0200 patch 8.2.3238: Vim9: error message does not indicate the location Problem: Vim9: error message does not indicate the location. Solution: Add the relevant text. (issue https://github.com/vim/vim/issues/8634)
author Bram Moolenaar <Bram@vim.org>
date Wed, 28 Jul 2021 21:00:04 +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