1
0
Fork 0
mirror of https://we.phorge.it/source/arcanist.git synced 2024-11-22 14:52:40 +01:00
phorge-arcanist/src/workflow/ArcanistBookmarksWorkflow.php

44 lines
1 KiB
PHP
Raw Permalink Normal View History

<?php
final class ArcanistBookmarksWorkflow
extends ArcanistMarkersWorkflow {
public function getWorkflowName() {
return 'bookmarks';
}
public function getWorkflowArguments() {
return array();
}
public function getWorkflowInformation() {
$help = pht(<<<EOHELP
Lists bookmarks in the working copy, annotated with additional information
about review status.
EOHELP
);
return $this->newWorkflowInformation()
->setSynopsis(
pht('Show an enhanced view of bookmarks in the working copy.'))
->addExample(pht('**bookmarks**'))
->setHelp($help);
}
protected function getWorkflowMarkerType() {
$api = $this->getRepositoryAPI();
$marker_type = ArcanistMarkerRef::TYPE_BOOKMARK;
if (!$this->hasMarkerTypeSupport($marker_type)) {
throw new PhutilArgumentUsageException(
pht(
'The version control system ("%s") in the current working copy '.
'does not support bookmarks.',
$api->getSourceControlSystemName()));
}
return $marker_type;
}
}