function drush_command_implements

8.0.x drush_command_implements($hook)
6.x drush_command_implements($hook)
7.x drush_command_implements($hook)
3.x drush_command_implements($hook)
4.x drush_command_implements($hook)
5.x drush_command_implements($hook)
master drush_command_implements($hook)

Determine which command files are implementing a hook.


$hook: The name of the hook (e.g. "drush_help" or "drush_command").

Return value

An array with the names of the command files which are implementing this hook.

3 calls to drush_command_implements()
drush_command in includes/
Entry point for commands into the drush_invoke() API
drush_command_invoke_all_ref in includes/
A drush_command_invoke_all() that wants the first parameter to be passed by reference.
make_validate_info_file in commands/make/
Validate the make file.


includes/, line 1280
The drush command engine.


function drush_command_implements($hook) {
  $implementations[$hook] = array();
  $list = drush_commandfile_list();
  foreach ($list as $commandfile => $file) {
    if (drush_command_hook($commandfile, $hook)) {
      $implementations[$hook][] = $commandfile;
  return (array) $implementations[$hook];