mirror of
https://we.phorge.it/source/phorge.git
synced 2025-01-25 14:08:19 +01:00
Remove product literal strings in "pht()", part 5
Summary: Ref T13658 Test Plan: This test plan is non-exhaustive. - Looked at some of the config. - Looked at guides. Maniphest Tasks: T13658 Differential Revision: https://secure.phabricator.com/D21769
This commit is contained in:
parent
d69da878d2
commit
ad880491e8
15 changed files with 45 additions and 34 deletions
|
@ -7,7 +7,7 @@ final class DarkConsoleEventPlugin extends DarkConsolePlugin {
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getDescription() {
|
public function getDescription() {
|
||||||
return pht('Information about Phabricator events and event listeners.');
|
return pht('Information about events and event listeners.');
|
||||||
}
|
}
|
||||||
|
|
||||||
public function generateData() {
|
public function generateData() {
|
||||||
|
|
|
@ -7,7 +7,7 @@ final class PhabricatorDaemonsApplication extends PhabricatorApplication {
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getShortDescription() {
|
public function getShortDescription() {
|
||||||
return pht('Manage Phabricator Daemons');
|
return pht('Manage Daemons');
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getBaseURI() {
|
public function getBaseURI() {
|
||||||
|
|
|
@ -93,7 +93,7 @@ abstract class PhabricatorDaemonManagementWorkflow
|
||||||
pht(
|
pht(
|
||||||
"You are trying to run a daemon as a nonstandard user, ".
|
"You are trying to run a daemon as a nonstandard user, ".
|
||||||
"and `%s` was not able to `%s` to the correct user. \n".
|
"and `%s` was not able to `%s` to the correct user. \n".
|
||||||
'Phabricator is configured to run daemons as "%s", '.
|
'The daemons are configured to run as "%s", '.
|
||||||
'but the current user is "%s". '."\n".
|
'but the current user is "%s". '."\n".
|
||||||
'Use `%s` to run as a different user, pass `%s` to ignore this '.
|
'Use `%s` to run as a different user, pass `%s` to ignore this '.
|
||||||
'warning, or edit `%s` to change the configuration.',
|
'warning, or edit `%s` to change the configuration.',
|
||||||
|
@ -154,7 +154,7 @@ abstract class PhabricatorDaemonManagementWorkflow
|
||||||
SIGINT,
|
SIGINT,
|
||||||
array(__CLASS__, 'ignoreSignal'));
|
array(__CLASS__, 'ignoreSignal'));
|
||||||
|
|
||||||
echo "\n phabricator/scripts/daemon/ \$ {$command}\n\n";
|
echo "\n scripts/daemon/ \$ {$command}\n\n";
|
||||||
|
|
||||||
$tempfile = new TempFile('daemon.config');
|
$tempfile = new TempFile('daemon.config');
|
||||||
Filesystem::writeFile($tempfile, json_encode($config));
|
Filesystem::writeFile($tempfile, json_encode($config));
|
||||||
|
@ -579,7 +579,7 @@ abstract class PhabricatorDaemonManagementWorkflow
|
||||||
$console->writeErr(
|
$console->writeErr(
|
||||||
"%s\n",
|
"%s\n",
|
||||||
pht(
|
pht(
|
||||||
'PID "%d" is not a known Phabricator daemon PID.',
|
'PID "%d" is not a known daemon PID.',
|
||||||
$pid));
|
$pid));
|
||||||
continue;
|
continue;
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -194,7 +194,7 @@ final class PhabricatorDashboardQueryPanelType
|
||||||
if (!$engine) {
|
if (!$engine) {
|
||||||
throw new Exception(
|
throw new Exception(
|
||||||
pht(
|
pht(
|
||||||
'The application search engine "%s" is not known to Phabricator!',
|
'The application search engine "%s" is unknown.',
|
||||||
$class));
|
$class));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1816,7 +1816,7 @@ final class DifferentialChangesetParser extends Phobject {
|
||||||
$viewstate = $this->getViewState();
|
$viewstate = $this->getViewState();
|
||||||
|
|
||||||
$engine_key = $viewstate->getDocumentEngineKey();
|
$engine_key = $viewstate->getDocumentEngineKey();
|
||||||
if (strlen($engine_key)) {
|
if (phutil_nonempty_string($engine_key)) {
|
||||||
if (isset($shared_engines[$engine_key])) {
|
if (isset($shared_engines[$engine_key])) {
|
||||||
$document_engine = $shared_engines[$engine_key];
|
$document_engine = $shared_engines[$engine_key];
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -76,7 +76,7 @@ abstract class DifferentialChangesetTestRenderer
|
||||||
$any_new = true;
|
$any_new = true;
|
||||||
}
|
}
|
||||||
$num = nonempty($p['line'], '-');
|
$num = nonempty($p['line'], '-');
|
||||||
$render = $p['render'];
|
$render = (string)$p['render'];
|
||||||
$htype = nonempty($p['htype'], '.');
|
$htype = nonempty($p['htype'], '.');
|
||||||
|
|
||||||
// TODO: This should probably happen earlier, whenever we deal with
|
// TODO: This should probably happen earlier, whenever we deal with
|
||||||
|
|
|
@ -550,9 +550,9 @@ final class DifferentialDiff
|
||||||
'buildable.revision' =>
|
'buildable.revision' =>
|
||||||
pht('The differential revision ID, if applicable.'),
|
pht('The differential revision ID, if applicable.'),
|
||||||
'repository.callsign' =>
|
'repository.callsign' =>
|
||||||
pht('The callsign of the repository in Phabricator.'),
|
pht('The callsign of the repository.'),
|
||||||
'repository.phid' =>
|
'repository.phid' =>
|
||||||
pht('The PHID of the repository in Phabricator.'),
|
pht('The PHID of the repository.'),
|
||||||
'repository.vcs' =>
|
'repository.vcs' =>
|
||||||
pht('The version control system, either "svn", "hg" or "git".'),
|
pht('The version control system, either "svn", "hg" or "git".'),
|
||||||
'repository.uri' =>
|
'repository.uri' =>
|
||||||
|
|
|
@ -130,19 +130,19 @@ final class DiffusionRepositoryURIsManagementPanel
|
||||||
$messages = array();
|
$messages = array();
|
||||||
if ($repository->isHosted()) {
|
if ($repository->isHosted()) {
|
||||||
if ($is_new) {
|
if ($is_new) {
|
||||||
$host_message = pht('Phabricator will host this repository.');
|
$host_message = pht('This repository will be hosted.');
|
||||||
} else {
|
} else {
|
||||||
$host_message = pht('Phabricator is hosting this repository.');
|
$host_message = pht('This repository is observed.');
|
||||||
}
|
}
|
||||||
|
|
||||||
$messages[] = $host_message;
|
$messages[] = $host_message;
|
||||||
} else {
|
} else {
|
||||||
if ($is_new) {
|
if ($is_new) {
|
||||||
$observe_message = pht(
|
$observe_message = pht(
|
||||||
'Phabricator will observe a remote repository.');
|
'This repository will be observed.');
|
||||||
} else {
|
} else {
|
||||||
$observe_message = pht(
|
$observe_message = pht(
|
||||||
'This repository is hosted remotely. Phabricator is observing it.');
|
'This remote repository is being observed.');
|
||||||
}
|
}
|
||||||
|
|
||||||
$messages[] = $observe_message;
|
$messages[] = $observe_message;
|
||||||
|
|
|
@ -158,7 +158,7 @@ abstract class DoorkeeperFeedWorker extends FeedPushWorker {
|
||||||
*/
|
*/
|
||||||
final protected function doWork() {
|
final protected function doWork() {
|
||||||
if (PhabricatorEnv::getEnvConfig('phabricator.silent')) {
|
if (PhabricatorEnv::getEnvConfig('phabricator.silent')) {
|
||||||
$this->log("%s\n", pht('Phabricator is running in silent mode.'));
|
$this->log("%s\n", pht('This software is running in silent mode.'));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -24,7 +24,7 @@ final class PhabricatorFeedConfigOptions
|
||||||
IMPORTANT: Feed hooks are deprecated and have been replaced by Webhooks.
|
IMPORTANT: Feed hooks are deprecated and have been replaced by Webhooks.
|
||||||
|
|
||||||
You can configure Webhooks in Herald. This configuration option will be removed
|
You can configure Webhooks in Herald. This configuration option will be removed
|
||||||
in a future version of Phabricator.
|
in a future version of the software.
|
||||||
|
|
||||||
(This legacy option may be configured with a list of URIs; feed stories will
|
(This legacy option may be configured with a list of URIs; feed stories will
|
||||||
send to these URIs.)
|
send to these URIs.)
|
||||||
|
|
|
@ -112,6 +112,11 @@ final class PhabricatorDocumentRef
|
||||||
|
|
||||||
public function hasAnyMimeType(array $candidate_types) {
|
public function hasAnyMimeType(array $candidate_types) {
|
||||||
$mime_full = $this->getMimeType();
|
$mime_full = $this->getMimeType();
|
||||||
|
|
||||||
|
if (!phutil_nonempty_string($mime_full)) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
$mime_parts = explode(';', $mime_full);
|
$mime_parts = explode(';', $mime_full);
|
||||||
|
|
||||||
$mime_type = head($mime_parts);
|
$mime_type = head($mime_parts);
|
||||||
|
|
|
@ -14,8 +14,12 @@ final class PhabricatorJSONDocumentEngine
|
||||||
}
|
}
|
||||||
|
|
||||||
protected function getContentScore(PhabricatorDocumentRef $ref) {
|
protected function getContentScore(PhabricatorDocumentRef $ref) {
|
||||||
if (preg_match('/\.json\z/', $ref->getName())) {
|
|
||||||
return 2000;
|
$name = $ref->getName();
|
||||||
|
if ($name !== null) {
|
||||||
|
if (preg_match('/\.json\z/', $name)) {
|
||||||
|
return 2000;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($ref->isProbablyJSON()) {
|
if ($ref->isProbablyJSON()) {
|
||||||
|
|
|
@ -15,8 +15,11 @@ final class PhabricatorRemarkupDocumentEngine
|
||||||
|
|
||||||
protected function getContentScore(PhabricatorDocumentRef $ref) {
|
protected function getContentScore(PhabricatorDocumentRef $ref) {
|
||||||
$name = $ref->getName();
|
$name = $ref->getName();
|
||||||
if (preg_match('/\\.remarkup\z/i', $name)) {
|
|
||||||
return 2000;
|
if ($name !== null) {
|
||||||
|
if (preg_match('/\\.remarkup\z/i', $name)) {
|
||||||
|
return 2000;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return 500;
|
return 500;
|
||||||
|
|
|
@ -7,7 +7,7 @@ final class PhabricatorGuideInstallModule extends PhabricatorGuideModule {
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getModuleName() {
|
public function getModuleName() {
|
||||||
return pht('Install Phabricator');
|
return pht('Install');
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getModulePosition() {
|
public function getModulePosition() {
|
||||||
|
@ -66,7 +66,7 @@ final class PhabricatorGuideInstallModule extends PhabricatorGuideModule {
|
||||||
$icon_bg = 'bg-sky';
|
$icon_bg = 'bg-sky';
|
||||||
$description = pht(
|
$description = pht(
|
||||||
'Authentication providers allow users to register accounts and '.
|
'Authentication providers allow users to register accounts and '.
|
||||||
'log in to Phabricator.');
|
'log in.');
|
||||||
}
|
}
|
||||||
|
|
||||||
$item = id(new PhabricatorGuideItemView())
|
$item = id(new PhabricatorGuideItemView())
|
||||||
|
@ -78,7 +78,7 @@ final class PhabricatorGuideInstallModule extends PhabricatorGuideModule {
|
||||||
$guide_items->addItem($item);
|
$guide_items->addItem($item);
|
||||||
|
|
||||||
|
|
||||||
$title = pht('Configure Phabricator');
|
$title = pht('Configure');
|
||||||
$href = PhabricatorEnv::getURI('/config/');
|
$href = PhabricatorEnv::getURI('/config/');
|
||||||
|
|
||||||
// Just load any config value at all; if one exists the install has figured
|
// Just load any config value at all; if one exists the install has figured
|
||||||
|
@ -95,7 +95,7 @@ final class PhabricatorGuideInstallModule extends PhabricatorGuideModule {
|
||||||
$icon = 'fa-sliders';
|
$icon = 'fa-sliders';
|
||||||
$icon_bg = 'bg-sky';
|
$icon_bg = 'bg-sky';
|
||||||
$description = pht(
|
$description = pht(
|
||||||
'Learn how to configure mail and other options in Phabricator.');
|
'Learn how to configure mail and other options.');
|
||||||
}
|
}
|
||||||
|
|
||||||
$item = id(new PhabricatorGuideItemView())
|
$item = id(new PhabricatorGuideItemView())
|
||||||
|
@ -148,7 +148,7 @@ final class PhabricatorGuideInstallModule extends PhabricatorGuideModule {
|
||||||
$icon = 'fa-bell';
|
$icon = 'fa-bell';
|
||||||
$icon_bg = 'bg-sky';
|
$icon_bg = 'bg-sky';
|
||||||
$description = pht(
|
$description = pht(
|
||||||
'Phabricator can deliver notifications in real-time with WebSockets.');
|
'Real-time notifications can be delivered with WebSockets.');
|
||||||
}
|
}
|
||||||
|
|
||||||
$item = id(new PhabricatorGuideItemView())
|
$item = id(new PhabricatorGuideItemView())
|
||||||
|
@ -161,11 +161,12 @@ final class PhabricatorGuideInstallModule extends PhabricatorGuideModule {
|
||||||
$guide_items->addItem($item);
|
$guide_items->addItem($item);
|
||||||
|
|
||||||
$intro = pht(
|
$intro = pht(
|
||||||
'Phabricator has been successfully installed. These next guides will '.
|
'%s has been successfully installed. These next guides will '.
|
||||||
'take you through configuration and new user orientation. '.
|
'take you through configuration and new user orientation. '.
|
||||||
'These steps are optional, and you can go through them in any order. '.
|
'These steps are optional, and you can go through them in any order. '.
|
||||||
'If you want to get back to this guide later on, you can find it in '.
|
'If you want to get back to this guide later on, you can find it in '.
|
||||||
'{icon globe} **Applications** under {icon map-o} **Guides**.');
|
'{icon globe} **Applications** under {icon map-o} **Guides**.',
|
||||||
|
PlatformSymbols::getPlatformServerName());
|
||||||
|
|
||||||
$intro = new PHUIRemarkupView($viewer, $intro);
|
$intro = new PHUIRemarkupView($viewer, $intro);
|
||||||
|
|
||||||
|
|
|
@ -132,7 +132,7 @@ final class PhabricatorGuideQuickStartModule extends PhabricatorGuideModule {
|
||||||
$icon = 'fa-globe';
|
$icon = 'fa-globe';
|
||||||
$icon_bg = 'bg-sky';
|
$icon_bg = 'bg-sky';
|
||||||
$description =
|
$description =
|
||||||
pht('See all the applications included in Phabricator.');
|
pht('See all available applications.');
|
||||||
|
|
||||||
$item = id(new PhabricatorGuideItemView())
|
$item = id(new PhabricatorGuideItemView())
|
||||||
->setTitle($title)
|
->setTitle($title)
|
||||||
|
@ -159,7 +159,7 @@ final class PhabricatorGuideQuickStartModule extends PhabricatorGuideModule {
|
||||||
$icon = 'fa-group';
|
$icon = 'fa-group';
|
||||||
$icon_bg = 'bg-sky';
|
$icon_bg = 'bg-sky';
|
||||||
$description =
|
$description =
|
||||||
pht('Invite the rest of your team to get started on Phabricator.');
|
pht('Invite the rest of your team to get started.');
|
||||||
}
|
}
|
||||||
|
|
||||||
$item = id(new PhabricatorGuideItemView())
|
$item = id(new PhabricatorGuideItemView())
|
||||||
|
@ -172,11 +172,9 @@ final class PhabricatorGuideQuickStartModule extends PhabricatorGuideModule {
|
||||||
}
|
}
|
||||||
|
|
||||||
$intro = pht(
|
$intro = pht(
|
||||||
'If you\'re new to Phabricator, these optional steps can help you learn '.
|
'If you\'re new to this software, these optional steps can help you '.
|
||||||
'the basics. Conceptually, Phabricator is structured as a graph, and '.
|
'learn the basics. Feel free to set things up for how you work best '.
|
||||||
'repositories, tasks, and projects are all independent from each other. '.
|
'and explore these features at your own pace.');
|
||||||
'Feel free to set up Phabricator for how you work best, and explore '.
|
|
||||||
'these features at your own pace.');
|
|
||||||
|
|
||||||
$intro = new PHUIRemarkupView($viewer, $intro);
|
$intro = new PHUIRemarkupView($viewer, $intro);
|
||||||
$intro = id(new PHUIDocumentView())
|
$intro = id(new PHUIDocumentView())
|
||||||
|
|
Loading…
Add table
Reference in a new issue