0;"); } /** * Take action before modules are disabled in a major upgrade. * Note that when this hook fires, it will be operating on a * copy of the database. */ function drush_hook_pre_site_upgrade_prepare() { // site upgrade prepare will disable contrib_extensions and // uninstall the uninstall_extension $contrib_extensions = func_get_args(); $uninstall_extensions = explode(',', drush_get_option('uninstall', '')); } /** * Add help components to a command */ function hook_drush_help_alter(&$command) { if ($command['command'] == 'sql-sync') { $command['options']['myoption'] = "Description of modification of sql-sync done by hook"; $command['sub-options']['sanitize']['my-sanitize-option'] = "Description of sanitization option added by hook (grouped with --sanitize option)"; } } /** * Add/edit options to cache-clear command */ function hook_drush_cache_clear(&$types) { $types['views'] = 'views_invalidate_cache'; } /* * Make shell aliases and other .bashrc code available during core-cli command. * * @return * Bash code typically found in a .bashrc file. * * @see core_cli_bashrc() for an example implementation. */ function hook_cli_bashrc() { $string = " alias siwef='drush site-install wef --account-name=super --account-mail=me@wef' alias dump='drush sql-dump --structure-tables-key=wef --ordered-dump' "; return $string; } /** * @} End of "addtogroup hooks". */