function drush_core_cron

8.0.x drush_core_cron()
6.x drush_core_cron()
7.x drush_core_cron()
3.x drush_core_cron()
4.x drush_core_cron()
5.x drush_core_cron()
master drush_core_cron()

Command callback. Runs cron hooks.

This is where the action takes place.

In this function, all of Drupals API is (usually) available, including any functions you have added in your own modules/themes.

To print something to the terminal window, use drush_print().


commands/core/, line 512
Core drush commands.


function drush_core_cron() {
  if (drupal_cron_run()) {
    drush_log(dt('Cron run successfully.'), 'success');
  else {
    return drush_set_error('DRUSH_CRON_FAILED', dt('Cron run failed.'));