view src/which.sh @ 23616:8b6d289d182e v8.2.2350

patch 8.2.2350: using "void" for no reason Commit: https://github.com/vim/vim/commit/033135eb8eccd00c9ee72c6c0cf4b8b9f81bd269 Author: Bram Moolenaar <Bram@vim.org> Date: Thu Jan 14 21:40:22 2021 +0100 patch 8.2.2350: using "void" for no reason Problem: Using "void" for no reason. Solution: Use "char *".
author Bram Moolenaar <Bram@vim.org>
date Thu, 14 Jan 2021 21:45:05 +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