public function drush_pm_version_control_bzr::bzr_get_repository_root

3.x bzr.inc public drush_pm_version_control_bzr::bzr_get_repository_root($path)

Helper function: get the root of a repository path.

Parameters

$path: The path to check.

Return value

An absolute path to the repository root.

File

commands/pm/version_control/bzr.inc, line 17
Drush pm BZR extension

Class

drush_pm_version_control_bzr

Code

public function bzr_get_repository_root($path) {
  if (drush_shell_exec('bzr root %s', $path)) {
    $output = drush_shell_exec_output();
    return reset($output);
  }
}