function package_handler_install_project

3.x wget.inc package_handler_install_project(&$project, $release)
3.x cvs.inc package_handler_install_project($project, $release)

Install a project.

Parameters

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

$release The release details array from drupal.org:

2 calls to package_handler_install_project()
drush_pm_download in commands/pm/pm.drush.inc
Command callback. Download Drupal core or any project.
package_handler_update_project in commands/pm/package_handler/wget.inc
This is an alias of the install function, since they are identical

File

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

Code

function package_handler_install_project($project, $release) {
  drush_log('Downloading project ' . $project['name'] . ' ...');

  // Check it out.
  drush_pm_cvs($project, $release);

  if (!drush_get_context('DRUSH_SIMULATE')) {
    if (is_dir($project['full_project_path'])) {
      drush_log("Checking out " . $project['name'] . " was successful.");
      return TRUE;
    }
    else {
      drush_set_error('DRUSH_PM_CVS_CHECKOUT_PROBLEMS', dt("Unable to check out !project to !destination from cvs.drupal.org", array('!project' => $project['name'], '!destination' => $project['full_project_path'])));
      return FALSE;
    }
  }
}