1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-25 08:12:40 +01:00
phorge-phorge/src/applications/lipsum/management/PhabricatorLipsumGenerateWorkflow.php

31 lines
814 B
PHP
Raw Normal View History

<?php
final class PhabricatorLipsumGenerateWorkflow
extends PhabricatorLipsumManagementWorkflow {
protected function didConstruct() {
$this
->setName('generate')
->setExamples('**generate**')
->setSynopsis('Generate some lipsum.')
->setArguments(
array(
array(
'name' => 'args',
'wildcard' => true,
),
));
}
public function execute(PhutilArgumentParser $args) {
$admin = PhabricatorUser::getOmnipotentUser();
$peoplegen = new PhabricatorPeopleTestDataGenerator();
$object = $peoplegen->generate();
$handle = PhabricatorObjectHandleData::loadOneHandle($object->getPHID(),
$admin);
echo "Generated ".$handle->getFullName()."\n";
echo "\nRequested data has been generated.";
}
}