phtize all the things
Summary: `pht`ize a whole bunch of strings in rP. Test Plan: Intense eyeballing. Reviewers: #blessed_reviewers, epriestley Reviewed By: #blessed_reviewers, epriestley Subscribers: hach-que, Korvin, epriestley Differential Revision: https://secure.phabricator.com/D12797
This commit is contained in:
@@ -32,7 +32,7 @@ final class PhabricatorFactChartController extends PhabricatorFactController {
|
||||
|
||||
if (!$points) {
|
||||
// NOTE: Raphael crashes Safari if you hand it series with no points.
|
||||
throw new Exception('No data to show!');
|
||||
throw new Exception(pht('No data to show!'));
|
||||
}
|
||||
|
||||
// Limit amount of data passed to browser.
|
||||
|
||||
@@ -15,7 +15,7 @@ final class PhabricatorFactDaemon extends PhabricatorDaemon {
|
||||
}
|
||||
$this->processAggregates();
|
||||
|
||||
$this->log('Zzz...');
|
||||
$this->log(pht('Zzz...'));
|
||||
$this->sleep(60 * 5);
|
||||
}
|
||||
}
|
||||
@@ -35,7 +35,7 @@ final class PhabricatorFactDaemon extends PhabricatorDaemon {
|
||||
}
|
||||
|
||||
public function processIteratorWithCursor($iterator_name, $iterator) {
|
||||
$this->log("Processing cursor '{$iterator_name}'.");
|
||||
$this->log(pht("Processing cursor '%s'.", $iterator_name));
|
||||
|
||||
$cursor = id(new PhabricatorFactCursor())->loadOneWhere(
|
||||
'name = %s',
|
||||
@@ -73,7 +73,7 @@ final class PhabricatorFactDaemon extends PhabricatorDaemon {
|
||||
$raw_facts = array();
|
||||
foreach ($iterator as $key => $object) {
|
||||
$phid = $object->getPHID();
|
||||
$this->log("Processing {$phid}...");
|
||||
$this->log(pht('Processing %s...', $phid));
|
||||
$raw_facts[$phid] = $this->computeRawFacts($object);
|
||||
if (count($raw_facts) > self::RAW_FACT_BUFFER_LIMIT) {
|
||||
$this->updateRawFacts($raw_facts);
|
||||
@@ -91,7 +91,7 @@ final class PhabricatorFactDaemon extends PhabricatorDaemon {
|
||||
}
|
||||
|
||||
public function processAggregates() {
|
||||
$this->log('Processing aggregates.');
|
||||
$this->log(pht('Processing aggregates.'));
|
||||
|
||||
$facts = $this->computeAggregateFacts();
|
||||
$this->updateAggregateFacts($facts);
|
||||
|
||||
@@ -10,9 +10,9 @@ final class PhabricatorFactCountEngine extends PhabricatorFactEngine {
|
||||
foreach ($fact_types as $type) {
|
||||
if (!strncmp($type, '+N:', 3)) {
|
||||
if ($type == '+N:*') {
|
||||
$name = 'Total Objects';
|
||||
$name = pht('Total Objects');
|
||||
} else {
|
||||
$name = 'Total Objects of type '.substr($type, 3);
|
||||
$name = pht('Total Objects of type %s', substr($type, 3));
|
||||
}
|
||||
|
||||
$results[] = id(new PhabricatorFactSimpleSpec($type))
|
||||
@@ -22,9 +22,9 @@ final class PhabricatorFactCountEngine extends PhabricatorFactEngine {
|
||||
|
||||
if (!strncmp($type, 'N:', 2)) {
|
||||
if ($type == 'N:*') {
|
||||
$name = 'Objects';
|
||||
$name = pht('Objects');
|
||||
} else {
|
||||
$name = 'Objects of type '.substr($type, 2);
|
||||
$name = pht('Objects of type %s', substr($type, 2));
|
||||
}
|
||||
$results[] = id(new PhabricatorFactSimpleSpec($type))
|
||||
->setName($name)
|
||||
|
||||
@@ -10,7 +10,7 @@ final class PhabricatorFactLastUpdatedEngine extends PhabricatorFactEngine {
|
||||
foreach ($fact_types as $type) {
|
||||
if ($type == 'updated') {
|
||||
$results[] = id(new PhabricatorFactSimpleSpec($type))
|
||||
->setName('Facts Last Updated')
|
||||
->setName(pht('Facts Last Updated'))
|
||||
->setUnit(PhabricatorFactSimpleSpec::UNIT_EPOCH);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
/**
|
||||
* Iterate over objects by update time in a stable way. This iterator only works
|
||||
* for "normal" Lisk objects: objects with an autoincrement ID and a
|
||||
* for "normal" Lisk objects: objects with an auto-increment ID and a
|
||||
* dateModified column.
|
||||
*/
|
||||
final class PhabricatorFactUpdateIterator extends PhutilBufferedIterator {
|
||||
|
||||
@@ -13,15 +13,15 @@ final class PhabricatorFactManagementAnalyzeWorkflow
|
||||
'name' => 'iterator',
|
||||
'param' => 'name',
|
||||
'repeat' => true,
|
||||
'help' => 'Process only iterator __name__.',
|
||||
'help' => pht('Process only iterator __name__.'),
|
||||
),
|
||||
array(
|
||||
'name' => 'all',
|
||||
'help' => 'Analyze from the beginning, ignoring cursors.',
|
||||
'help' => pht('Analyze from the beginning, ignoring cursors.'),
|
||||
),
|
||||
array(
|
||||
'name' => 'skip-aggregates',
|
||||
'help' => 'Skip analysis of aggreate facts.',
|
||||
'help' => pht('Skip analysis of aggregate facts.'),
|
||||
),
|
||||
));
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@ final class PhabricatorFactManagementCursorsWorkflow
|
||||
'name' => 'reset',
|
||||
'param' => 'cursor',
|
||||
'repeat' => true,
|
||||
'help' => 'Reset cursor __cursor__.',
|
||||
'help' => pht('Reset cursor __cursor__.'),
|
||||
),
|
||||
));
|
||||
}
|
||||
|
||||
@@ -33,8 +33,9 @@ abstract class PhabricatorFactSpec {
|
||||
}
|
||||
|
||||
public function getName() {
|
||||
$type = $this->getType();
|
||||
return "Fact ({$type})";
|
||||
return pht(
|
||||
'Fact (%s)',
|
||||
$this->getType());
|
||||
}
|
||||
|
||||
public function formatValueForDisplay(PhabricatorUser $user, $value) {
|
||||
|
||||
Reference in New Issue
Block a user