view src/which.sh @ 27680:38eab98ef5a9 v8.2.4366

patch 8.2.4366: not enough tests for command line completion Commit: https://github.com/vim/vim/commit/4d03d870007c593bce2cfa8d0a6597ca3a20fa35 Author: Yegappan Lakshmanan <yegappan@yahoo.com> Date: Sun Feb 13 11:45:09 2022 +0000 patch 8.2.4366: not enough tests for command line completion Problem: Not enough tests for command line completion. Solution: Add a few more tests. (Yegappan Lakshmanan, closes https://github.com/vim/vim/issues/9760)
author Bram Moolenaar <Bram@vim.org>
date Sun, 13 Feb 2022 13:00:04 +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