view src/which.sh @ 5164:b3bd43ef012d v7.4a.008

updated for version 7.4a.008 Problem: Python 3 doesn't handle multibyte characters prooperly when 'encoding' is not utf-8. Solution: Use PyUnicode_Decode() instead of PyUnicode_FromString(). (Ken Takata)
author Bram Moolenaar <bram@vim.org>
date Tue, 09 Jul 2013 17:30:55 +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