view src/which.sh @ 23677:94409ebb33f1 v8.2.2380

patch 8.2.2380: Vim9: occasional crash when using try/catch and a timer Commit: https://github.com/vim/vim/commit/a0f7f73ebb3ab032af08699c24c465403512b7d8 Author: Bram Moolenaar <Bram@vim.org> Date: Wed Jan 20 22:22:49 2021 +0100 patch 8.2.2380: Vim9: occasional crash when using try/catch and a timer Problem: Vim9: occasional crash when using try/catch and a timer. Solution: Save and restore "need_rethrow" when invoking a timer callback. (closes #7708)
author Bram Moolenaar <Bram@vim.org>
date Wed, 20 Jan 2021 22:30:04 +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