# which(3)

[Home] [Commands] [Variables] [Macro-Dev] [Glossary]

## NAME

which - Program finder
.which.result - Program path

## SYNOPSIS

which "progname"
.which.result "string"

## DESCRIPTION

which searches for the given program "progname" on the system path (set by the environment variable $PATH). If found the location is printed on the message line, otherwise an error message is printed and the command fails.

The variable .which.result is set to the last found program or the string "`ERROR`" if the program was not found.

## NOTES

which is a macro defined in `tools.emf`, it uses the &which(4) macro function.

## SEE ALSO

&which(4).

(c) Copyright JASSPA 2009
Last Modified: 2009/08/29
Generated On: 2009/10/12

</HMTL>