function drush_which

8.0.x exec.inc drush_which($command)
master exec.inc drush_which($command)

Determine whether 'which $command' can find a command on this system.

Related topics

1 call to drush_which()
drush_init_core_init in commands/core/init.drush.inc
Initialize local Drush configuration

File

includes/exec.inc, line 174
Functions for executing system commands. (e.g. exec(), system(), ...).

Code

function drush_which($command) {
  exec("which $command 2>&1", $output, $result);
  return ($result == 0);
}