Differential D15662 Diff 37755 src/infrastructure/storage/management/workflow/PhabricatorStorageManagementWorkflow.php
Changeset View
Changeset View
Standalone View
Standalone View
src/infrastructure/storage/management/workflow/PhabricatorStorageManagementWorkflow.php
Show First 20 Lines • Show All 44 Lines • ▼ Show 20 Lines | public function setPatches(array $patches) { | ||||
return $this; | return $this; | ||||
} | } | ||||
public function execute(PhutilArgumentParser $args) { | public function execute(PhutilArgumentParser $args) { | ||||
$this->setDryRun($args->getArg('dryrun')); | $this->setDryRun($args->getArg('dryrun')); | ||||
$this->setForce($args->getArg('force')); | $this->setForce($args->getArg('force')); | ||||
if (PhabricatorEnv::isReadOnly()) { | |||||
if ($this->isForce()) { | |||||
PhabricatorEnv::setReadOnly(false); | |||||
} else { | |||||
throw new PhutilArgumentUsageException( | |||||
pht( | |||||
'Phabricator is currently in read-only mode. Use --force to '. | |||||
'override this mode.')); | |||||
} | |||||
} | |||||
$this->didExecute($args); | $this->didExecute($args); | ||||
} | } | ||||
public function didExecute(PhutilArgumentParser $args) {} | public function didExecute(PhutilArgumentParser $args) {} | ||||
private function loadSchemata() { | private function loadSchemata() { | ||||
$query = id(new PhabricatorConfigSchemaQuery()) | $query = id(new PhabricatorConfigSchemaQuery()) | ||||
->setAPI($this->getAPI()); | ->setAPI($this->getAPI()); | ||||
▲ Show 20 Lines • Show All 875 Lines • Show Last 20 Lines |