function drush_module_list

8.0.x environment_7.inc drush_module_list()
8.0.x environment_6.inc drush_module_list()
8.0.x environment.inc drush_module_list()
6.x environment_7.inc drush_module_list()
6.x environment_6.inc drush_module_list()
6.x environment.inc drush_module_list()
7.x environment_7.inc drush_module_list()
7.x environment_6.inc drush_module_list()
7.x environment.inc drush_module_list()
master environment_7.inc drush_module_list()
master environment.inc drush_module_list()

Returns a list of enabled modules.

This is a simplified version of module_list().

6 calls to drush_module_list()
DrupalBoot::commandfile_searchpaths in lib/Drush/Boot/DrupalBoot.php
drush_core_twig_compile in commands/core/core.drush.inc
drush_pm_enable_validate in commands/pm/pm.drush.inc
Validate callback. Determine the modules and themes that the user would like enabled.
drush_pm_updatecode_postupdate in commands/pm/pm.drush.inc
Command callback. Execute updatecode-postupdate.
RoleBase::getAllModulePerms in lib/Drush/Role/RoleBase.php

... See full list

File

commands/core/drupal/environment_7.inc, line 110
Specific functions for a drupal 7 environment. drush_include_engine() magically includes either this file or environment_X.inc depending on which version of drupal drush is called from.

Code

function drush_module_list() {
  $enabled = array();
  $rsc = drush_db_select('system', 'name', 'type=:type AND status=:status', array(':type' => 'module', ':status' => 1));
  while ($row = drush_db_result($rsc)) {
    $enabled[$row] = $row;
  }

  return $enabled;
}