view src/which.sh @ 25984:c8fcea636252 v8.2.3525

patch 8.2.3525: option variable name does not match option name Commit: https://github.com/vim/vim/commit/d4c4bfa0078a959ff90ef30288fd31d9d38f23d7 Author: Bram Moolenaar <Bram@vim.org> Date: Sat Oct 16 21:14:11 2021 +0100 patch 8.2.3525: option variable name does not match option name Problem: Option variable name does not match option name. (Christ van Willigen) Solution: Rename the variable.
author Bram Moolenaar <Bram@vim.org>
date Sat, 16 Oct 2021 22:15: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