view src/which.sh @ 30073:c9fe7d5e0f61 v9.0.0374

patch 9.0.0374: Coverity still complains about dropping sign of character Commit: https://github.com/vim/vim/commit/3c7707680fea0881fe96c75f962af01edf810d5d Author: Bram Moolenaar <Bram@vim.org> Date: Sun Sep 4 11:55:19 2022 +0100 patch 9.0.0374: Coverity still complains about dropping sign of character Problem: Coverity still complains about dropping sign of character. Solution: Add intermediate variable.
author Bram Moolenaar <Bram@vim.org>
date Sun, 04 Sep 2022 13:00:03 +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