Changeset View
Changeset View
Standalone View
Standalone View
src/workflow/ArcanistLookWorkflow.php
Show First 20 Lines • Show All 134 Lines • ▼ Show 20 Lines | echo tsprintf( | ||||
"%W\n\n", | "%W\n\n", | ||||
pht( | pht( | ||||
'At the far edge of the grove, you see remotes:')); | 'At the far edge of the grove, you see remotes:')); | ||||
$api = $this->getRepositoryAPI(); | $api = $this->getRepositoryAPI(); | ||||
$remotes = $api->newRemoteRefQuery() | $remotes = $api->newRemoteRefQuery() | ||||
->execute(); | ->execute(); | ||||
$this->loadHardpoints( | |||||
$remotes, | |||||
ArcanistRemoteRef::HARDPOINT_REPOSITORYREFS); | |||||
foreach ($remotes as $remote) { | foreach ($remotes as $remote) { | ||||
$view = $remote->newRefView(); | $view = $remote->newRefView(); | ||||
$push_uri = $remote->getPushURI(); | $push_uri = $remote->getPushURI(); | ||||
if ($push_uri === null) { | if ($push_uri === null) { | ||||
$push_uri = '-'; | $push_uri = '-'; | ||||
} | } | ||||
$view->appendLine( | $view->appendLine( | ||||
pht( | pht( | ||||
'Push URI: %s', | 'Push URI: %s', | ||||
$push_uri)); | $push_uri)); | ||||
$push_repository = $remote->getPushRepositoryRef(); | |||||
if ($push_repository) { | |||||
$push_display = $push_repository->getDisplayName(); | |||||
} else { | |||||
$push_display = '-'; | |||||
} | |||||
$view->appendLine( | |||||
pht( | |||||
'Push Repository: %s', | |||||
$push_display)); | |||||
$fetch_uri = $remote->getFetchURI(); | $fetch_uri = $remote->getFetchURI(); | ||||
if ($fetch_uri === null) { | if ($fetch_uri === null) { | ||||
$fetch_uri = '-'; | $fetch_uri = '-'; | ||||
} | } | ||||
$view->appendLine( | $view->appendLine( | ||||
pht( | pht( | ||||
'Fetch URI: %s', | 'Fetch URI: %s', | ||||
$fetch_uri)); | $fetch_uri)); | ||||
$fetch_repository = $remote->getFetchRepositoryRef(); | |||||
if ($fetch_repository) { | |||||
$fetch_display = $fetch_repository->getDisplayName(); | |||||
} else { | |||||
$fetch_display = '-'; | |||||
} | |||||
$view->appendLine( | |||||
pht( | |||||
'Fetch Repository: %s', | |||||
$fetch_display)); | |||||
echo tsprintf('%s', $view); | echo tsprintf('%s', $view); | ||||
} | } | ||||
} | } | ||||
} | } |