view src/which.sh @ 26342:936f77929f16 v8.2.3702

patch 8.2.3702: first key in dict is seen as curly expression and fails Commit: https://github.com/vim/vim/commit/98cb90ef865089a5ddd20bc0303d449fb7d97fb2 Author: Bram Moolenaar <Bram@vim.org> Date: Tue Nov 30 11:56:22 2021 +0000 patch 8.2.3702: first key in dict is seen as curly expression and fails Problem: First key in dict is seen as curly expression and fails. Solution: Ignore failure of curly expression. (closes https://github.com/vim/vim/issues/9247)
author Bram Moolenaar <Bram@vim.org>
date Tue, 30 Nov 2021 13:00:06 +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