function package_handler_update_project

8.0.x wget.inc package_handler_update_project(&$request, $release)
8.0.x git_drupalorg.inc package_handler_update_project($request, $release)
6.x wget.inc package_handler_update_project(&$request, $release)
6.x git_drupalorg.inc package_handler_update_project($request, $release)
7.x wget.inc package_handler_update_project(&$request, $release)
7.x git_drupalorg.inc package_handler_update_project($request, $release)
3.x wget.inc package_handler_update_project(&$project, $release)
3.x cvs.inc package_handler_update_project($project, $release)
4.x wget.inc package_handler_update_project(&$request, $release)
4.x git_drupalorg.inc package_handler_update_project($request, $release)
4.x cvs.inc package_handler_update_project(&$project, $release)
5.x wget.inc package_handler_update_project(&$request, $release)
5.x git_drupalorg.inc package_handler_update_project($request, $release)
master wget.inc package_handler_update_project(&$request, $release)
master git_drupalorg.inc package_handler_update_project($request, $release)

Update a project (so far, only modules are supported).

Parameters

$project The project array with name, base and full (final) paths.:

$release The release details array from drupal.org:

1 call to package_handler_update_project()
pm_update_project in commands/pm/updatecode.pm.inc
Update one project -- a module, theme or Drupal core.

File

commands/pm/package_handler/cvs.inc, line 54
Drush PM CVS extension

Code

function package_handler_update_project(&$project, $release) {
  drush_log('Updating project ' . $project['name'] . ' ...');

  // Check out a fresh copy, or update an existing one.
  drush_pm_cvs($project, $release);

  if (is_dir($project['full_project_path']) && !drush_get_context('DRUSH_SIMULATE')) {
    drush_log("Updating of " . $project['name'] . " was successful.");
    return TRUE;
  }
  else {
    return drush_set_error('DRUSH_PM_CVS_UPDATE_PROBLEMS', dt("Unable to update !project from cvs.drupal.org", array('!project' => $project['name'])));
  }
}