view src/which.sh @ 15508:69207f77754a v8.1.0762

patch 8.1.0762: compiler warning commit https://github.com/vim/vim/commit/e40742526e6ea272c64ca393d7364e4023f4122c Author: Bram Moolenaar <Bram@vim.org> Date: Thu Jan 17 14:31:14 2019 +0100 patch 8.1.0762: compiler warning Problem: Compiler warning. Solution: Add type cast. (Mike Williams)
author Bram Moolenaar <Bram@vim.org>
date Thu, 17 Jan 2019 14:45:11 +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