Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15433240
D10027.id24102.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
22 KB
Referenced Files
None
Subscribers
None
D10027.id24102.diff
View Options
diff --git a/src/applications/audit/application/PhabricatorAuditApplication.php b/src/applications/audit/application/PhabricatorAuditApplication.php
--- a/src/applications/audit/application/PhabricatorAuditApplication.php
+++ b/src/applications/audit/application/PhabricatorAuditApplication.php
@@ -10,6 +10,10 @@
return 'audit';
}
+ public function getName() {
+ return pht('Audit');
+ }
+
public function getShortDescription() {
return pht('Browse and Audit Commits');
}
diff --git a/src/applications/auth/application/PhabricatorAuthApplication.php b/src/applications/auth/application/PhabricatorAuthApplication.php
--- a/src/applications/auth/application/PhabricatorAuthApplication.php
+++ b/src/applications/auth/application/PhabricatorAuthApplication.php
@@ -18,6 +18,10 @@
return $viewer->getIsAdmin();
}
+ public function getName() {
+ return pht('Auth');
+ }
+
public function getShortDescription() {
return pht('Login/Registration');
}
diff --git a/src/applications/base/PhabricatorApplication.php b/src/applications/base/PhabricatorApplication.php
--- a/src/applications/base/PhabricatorApplication.php
+++ b/src/applications/base/PhabricatorApplication.php
@@ -27,23 +27,21 @@
/* -( Application Information )-------------------------------------------- */
+ /**
+ * TODO: This should be abstract, but is not for historical reasons.
+ */
public function getName() {
-
- // TODO: This is sort of gross.
+ phutil_deprecated(
+ 'Automatic naming of `PhabricatorApplication` classes.',
+ 'You should override the `getName` method.');
$match = null;
-
- $regex = '/^Phabricator([A-Z][a-zA-Z]*)Application$/';
- if (preg_match($regex, get_class($this), $match)) {
- return $match[1];
- }
-
$regex = '/^PhabricatorApplication([A-Z][a-zA-Z]*)$/';
if (preg_match($regex, get_class($this), $match)) {
return $match[1];
}
- throw new Exception('Unable to determine application name automagically.');
+ throw new PhutilMethodNotImplementedException();
}
public function getShortDescription() {
diff --git a/src/applications/base/controller/__tests__/PhabricatorTestApplication.php b/src/applications/base/controller/__tests__/PhabricatorTestApplication.php
--- a/src/applications/base/controller/__tests__/PhabricatorTestApplication.php
+++ b/src/applications/base/controller/__tests__/PhabricatorTestApplication.php
@@ -4,6 +4,10 @@
private $policies = array();
+ public function getName() {
+ return pht('Test');
+ }
+
public function isUnlisted() {
return true;
}
diff --git a/src/applications/calendar/application/PhabricatorCalendarApplication.php b/src/applications/calendar/application/PhabricatorCalendarApplication.php
--- a/src/applications/calendar/application/PhabricatorCalendarApplication.php
+++ b/src/applications/calendar/application/PhabricatorCalendarApplication.php
@@ -2,6 +2,10 @@
final class PhabricatorCalendarApplication extends PhabricatorApplication {
+ public function getName() {
+ return pht('Calendar');
+ }
+
public function getShortDescription() {
return pht('Upcoming Events');
}
diff --git a/src/applications/chatlog/application/PhabricatorChatLogApplication.php b/src/applications/chatlog/application/PhabricatorChatLogApplication.php
--- a/src/applications/chatlog/application/PhabricatorChatLogApplication.php
+++ b/src/applications/chatlog/application/PhabricatorChatLogApplication.php
@@ -6,6 +6,10 @@
return '/chatlog/';
}
+ public function getName() {
+ return pht('ChatLog');
+ }
+
public function getShortDescription() {
return pht('IRC Logs');
}
diff --git a/src/applications/conduit/application/PhabricatorConduitApplication.php b/src/applications/conduit/application/PhabricatorConduitApplication.php
--- a/src/applications/conduit/application/PhabricatorConduitApplication.php
+++ b/src/applications/conduit/application/PhabricatorConduitApplication.php
@@ -18,6 +18,10 @@
return PhabricatorEnv::getDoclink('Conduit Technical Documentation');
}
+ public function getName() {
+ return pht('Conduit');
+ }
+
public function getShortDescription() {
return pht('Developer API');
}
diff --git a/src/applications/config/application/PhabricatorConfigApplication.php b/src/applications/config/application/PhabricatorConfigApplication.php
--- a/src/applications/config/application/PhabricatorConfigApplication.php
+++ b/src/applications/config/application/PhabricatorConfigApplication.php
@@ -26,6 +26,10 @@
return false;
}
+ public function getName() {
+ return 'Config';
+ }
+
public function getShortDescription() {
return pht('Configure Phabricator');
}
diff --git a/src/applications/conpherence/application/PhabricatorConpherenceApplication.php b/src/applications/conpherence/application/PhabricatorConpherenceApplication.php
--- a/src/applications/conpherence/application/PhabricatorConpherenceApplication.php
+++ b/src/applications/conpherence/application/PhabricatorConpherenceApplication.php
@@ -6,6 +6,10 @@
return '/conpherence/';
}
+ public function getName() {
+ return pht('Conpherence');
+ }
+
public function getShortDescription() {
return pht('Send Messages');
}
diff --git a/src/applications/countdown/application/PhabricatorCountdownApplication.php b/src/applications/countdown/application/PhabricatorCountdownApplication.php
--- a/src/applications/countdown/application/PhabricatorCountdownApplication.php
+++ b/src/applications/countdown/application/PhabricatorCountdownApplication.php
@@ -10,6 +10,10 @@
return 'countdown';
}
+ public function getName() {
+ return pht('Countdown');
+ }
+
public function getShortDescription() {
return pht('Countdown to Events');
}
diff --git a/src/applications/differential/application/PhabricatorDifferentialApplication.php b/src/applications/differential/application/PhabricatorDifferentialApplication.php
--- a/src/applications/differential/application/PhabricatorDifferentialApplication.php
+++ b/src/applications/differential/application/PhabricatorDifferentialApplication.php
@@ -6,6 +6,10 @@
return '/differential/';
}
+ public function getName() {
+ return pht('Differential');
+ }
+
public function getShortDescription() {
return pht('Review Code');
}
diff --git a/src/applications/diffusion/application/PhabricatorDiffusionApplication.php b/src/applications/diffusion/application/PhabricatorDiffusionApplication.php
--- a/src/applications/diffusion/application/PhabricatorDiffusionApplication.php
+++ b/src/applications/diffusion/application/PhabricatorDiffusionApplication.php
@@ -2,6 +2,10 @@
final class PhabricatorDiffusionApplication extends PhabricatorApplication {
+ public function getName() {
+ return pht('Diffusion');
+ }
+
public function getShortDescription() {
return pht('Host and Browse Repositories');
}
diff --git a/src/applications/diviner/application/PhabricatorDivinerApplication.php b/src/applications/diviner/application/PhabricatorDivinerApplication.php
--- a/src/applications/diviner/application/PhabricatorDivinerApplication.php
+++ b/src/applications/diviner/application/PhabricatorDivinerApplication.php
@@ -10,6 +10,10 @@
return 'diviner';
}
+ public function getName() {
+ return pht('Diviner');
+ }
+
public function getShortDescription() {
return pht('Documentation');
}
diff --git a/src/applications/doorkeeper/application/PhabricatorDoorkeeperApplication.php b/src/applications/doorkeeper/application/PhabricatorDoorkeeperApplication.php
--- a/src/applications/doorkeeper/application/PhabricatorDoorkeeperApplication.php
+++ b/src/applications/doorkeeper/application/PhabricatorDoorkeeperApplication.php
@@ -10,6 +10,10 @@
return false;
}
+ public function getName() {
+ return pht('Doorkeeper');
+ }
+
public function getShortDescription() {
return pht('Connect to Other Software');
}
diff --git a/src/applications/drydock/application/PhabricatorDrydockApplication.php b/src/applications/drydock/application/PhabricatorDrydockApplication.php
--- a/src/applications/drydock/application/PhabricatorDrydockApplication.php
+++ b/src/applications/drydock/application/PhabricatorDrydockApplication.php
@@ -6,6 +6,10 @@
return '/drydock/';
}
+ public function getName() {
+ return pht('Drydock');
+ }
+
public function getShortDescription() {
return pht('Allocate Software Resources');
}
diff --git a/src/applications/feed/application/PhabricatorFeedApplication.php b/src/applications/feed/application/PhabricatorFeedApplication.php
--- a/src/applications/feed/application/PhabricatorFeedApplication.php
+++ b/src/applications/feed/application/PhabricatorFeedApplication.php
@@ -6,6 +6,10 @@
return '/feed/';
}
+ public function getName() {
+ return pht('Feed');
+ }
+
public function getShortDescription() {
return pht('Review Recent Activity');
}
diff --git a/src/applications/files/application/PhabricatorFilesApplication.php b/src/applications/files/application/PhabricatorFilesApplication.php
--- a/src/applications/files/application/PhabricatorFilesApplication.php
+++ b/src/applications/files/application/PhabricatorFilesApplication.php
@@ -6,6 +6,10 @@
return '/file/';
}
+ public function getName() {
+ return pht('Files');
+ }
+
public function getShortDescription() {
return 'Store and Share Files';
}
diff --git a/src/applications/flag/application/PhabricatorFlagsApplication.php b/src/applications/flag/application/PhabricatorFlagsApplication.php
--- a/src/applications/flag/application/PhabricatorFlagsApplication.php
+++ b/src/applications/flag/application/PhabricatorFlagsApplication.php
@@ -2,6 +2,10 @@
final class PhabricatorFlagsApplication extends PhabricatorApplication {
+ public function getName() {
+ return pht('Flags');
+ }
+
public function getShortDescription() {
return pht('Personal Bookmarks');
}
diff --git a/src/applications/harbormaster/application/PhabricatorHarbormasterApplication.php b/src/applications/harbormaster/application/PhabricatorHarbormasterApplication.php
--- a/src/applications/harbormaster/application/PhabricatorHarbormasterApplication.php
+++ b/src/applications/harbormaster/application/PhabricatorHarbormasterApplication.php
@@ -6,6 +6,10 @@
return '/harbormaster/';
}
+ public function getName() {
+ return pht('Harbormaster');
+ }
+
public function getShortDescription() {
return pht('Build/CI');
}
diff --git a/src/applications/help/application/PhabricatorHelpApplication.php b/src/applications/help/application/PhabricatorHelpApplication.php
--- a/src/applications/help/application/PhabricatorHelpApplication.php
+++ b/src/applications/help/application/PhabricatorHelpApplication.php
@@ -2,6 +2,10 @@
final class PhabricatorHelpApplication extends PhabricatorApplication {
+ public function getName() {
+ return pht('Help');
+ }
+
public function canUninstall() {
return false;
}
diff --git a/src/applications/herald/application/PhabricatorHeraldApplication.php b/src/applications/herald/application/PhabricatorHeraldApplication.php
--- a/src/applications/herald/application/PhabricatorHeraldApplication.php
+++ b/src/applications/herald/application/PhabricatorHeraldApplication.php
@@ -10,6 +10,10 @@
return 'herald';
}
+ public function getName() {
+ return pht('Herald');
+ }
+
public function getShortDescription() {
return pht('Create Notification Rules');
}
diff --git a/src/applications/home/application/PhabricatorHomeApplication.php b/src/applications/home/application/PhabricatorHomeApplication.php
--- a/src/applications/home/application/PhabricatorHomeApplication.php
+++ b/src/applications/home/application/PhabricatorHomeApplication.php
@@ -8,6 +8,10 @@
return '/home/';
}
+ public function getName() {
+ return pht('Home');
+ }
+
public function getShortDescription() {
return pht('Command Center');
}
diff --git a/src/applications/legalpad/application/PhabricatorLegalpadApplication.php b/src/applications/legalpad/application/PhabricatorLegalpadApplication.php
--- a/src/applications/legalpad/application/PhabricatorLegalpadApplication.php
+++ b/src/applications/legalpad/application/PhabricatorLegalpadApplication.php
@@ -6,6 +6,10 @@
return '/legalpad/';
}
+ public function getName() {
+ return pht('Legalpad');
+ }
+
public function getShortDescription() {
return pht('Agreements and Signatures');
}
diff --git a/src/applications/macro/application/PhabricatorMacroApplication.php b/src/applications/macro/application/PhabricatorMacroApplication.php
--- a/src/applications/macro/application/PhabricatorMacroApplication.php
+++ b/src/applications/macro/application/PhabricatorMacroApplication.php
@@ -6,6 +6,10 @@
return '/macro/';
}
+ public function getName() {
+ return pht('Macro');
+ }
+
public function getShortDescription() {
return pht('Image Macros and Memes');
}
diff --git a/src/applications/maniphest/application/PhabricatorManiphestApplication.php b/src/applications/maniphest/application/PhabricatorManiphestApplication.php
--- a/src/applications/maniphest/application/PhabricatorManiphestApplication.php
+++ b/src/applications/maniphest/application/PhabricatorManiphestApplication.php
@@ -2,8 +2,12 @@
final class PhabricatorManiphestApplication extends PhabricatorApplication {
+ public function getName() {
+ return pht('Maniphest');
+ }
+
public function getShortDescription() {
- return 'Tasks and Bugs';
+ return pht('Tasks and Bugs');
}
public function getBaseURI() {
diff --git a/src/applications/meta/application/PhabricatorApplicationsApplication.php b/src/applications/meta/application/PhabricatorApplicationsApplication.php
--- a/src/applications/meta/application/PhabricatorApplicationsApplication.php
+++ b/src/applications/meta/application/PhabricatorApplicationsApplication.php
@@ -2,6 +2,10 @@
final class PhabricatorApplicationsApplication extends PhabricatorApplication {
+ public function getName() {
+ return pht('Applications');
+ }
+
public function canUninstall() {
return false;
}
diff --git a/src/applications/people/application/PhabricatorPeopleApplication.php b/src/applications/people/application/PhabricatorPeopleApplication.php
--- a/src/applications/people/application/PhabricatorPeopleApplication.php
+++ b/src/applications/people/application/PhabricatorPeopleApplication.php
@@ -2,6 +2,10 @@
final class PhabricatorPeopleApplication extends PhabricatorApplication {
+ public function getName() {
+ return pht('People');
+ }
+
public function getShortDescription() {
return pht('User Accounts and Profiles');
}
diff --git a/src/applications/phrequent/application/PhabricatorPhrequentApplication.php b/src/applications/phrequent/application/PhabricatorPhrequentApplication.php
--- a/src/applications/phrequent/application/PhabricatorPhrequentApplication.php
+++ b/src/applications/phrequent/application/PhabricatorPhrequentApplication.php
@@ -2,6 +2,10 @@
final class PhabricatorPhrequentApplication extends PhabricatorApplication {
+ public function getName() {
+ return pht('Phrequent');
+ }
+
public function getShortDescription() {
return pht('Track Time Spent');
}
diff --git a/src/applications/phriction/application/PhabricatorPhrictionApplication.php b/src/applications/phriction/application/PhabricatorPhrictionApplication.php
--- a/src/applications/phriction/application/PhabricatorPhrictionApplication.php
+++ b/src/applications/phriction/application/PhabricatorPhrictionApplication.php
@@ -2,6 +2,10 @@
final class PhabricatorPhrictionApplication extends PhabricatorApplication {
+ public function getName() {
+ return pht('Phriction');
+ }
+
public function getShortDescription() {
return pht('Wiki');
}
diff --git a/src/applications/policy/application/PhabricatorPolicyApplication.php b/src/applications/policy/application/PhabricatorPolicyApplication.php
--- a/src/applications/policy/application/PhabricatorPolicyApplication.php
+++ b/src/applications/policy/application/PhabricatorPolicyApplication.php
@@ -2,6 +2,10 @@
final class PhabricatorPolicyApplication extends PhabricatorApplication {
+ public function getName() {
+ return pht('Policy');
+ }
+
public function isLaunchable() {
return false;
}
diff --git a/src/applications/ponder/application/PhabricatorPonderApplication.php b/src/applications/ponder/application/PhabricatorPonderApplication.php
--- a/src/applications/ponder/application/PhabricatorPonderApplication.php
+++ b/src/applications/ponder/application/PhabricatorPonderApplication.php
@@ -6,6 +6,10 @@
return '/ponder/';
}
+ public function getName() {
+ return pht('Ponder');
+ }
+
public function getShortDescription() {
return pht('Questions and Answers');
}
diff --git a/src/applications/repository/application/PhabricatorRepositoriesApplication.php b/src/applications/repository/application/PhabricatorRepositoriesApplication.php
--- a/src/applications/repository/application/PhabricatorRepositoriesApplication.php
+++ b/src/applications/repository/application/PhabricatorRepositoriesApplication.php
@@ -10,6 +10,10 @@
return 'repositories';
}
+ public function getName() {
+ return pht('Repositories');
+ }
+
public function getShortDescription() {
return pht('(Deprecated)');
}
diff --git a/src/applications/settings/application/PhabricatorSettingsApplication.php b/src/applications/settings/application/PhabricatorSettingsApplication.php
--- a/src/applications/settings/application/PhabricatorSettingsApplication.php
+++ b/src/applications/settings/application/PhabricatorSettingsApplication.php
@@ -6,6 +6,10 @@
return '/settings/';
}
+ public function getName() {
+ return pht('Settings');
+ }
+
public function getShortDescription() {
return pht('User Preferences');
}
diff --git a/src/applications/slowvote/application/PhabricatorSlowvoteApplication.php b/src/applications/slowvote/application/PhabricatorSlowvoteApplication.php
--- a/src/applications/slowvote/application/PhabricatorSlowvoteApplication.php
+++ b/src/applications/slowvote/application/PhabricatorSlowvoteApplication.php
@@ -10,8 +10,12 @@
return 'slowvote';
}
+ public function getName() {
+ return pht('Slowvote');
+ }
+
public function getShortDescription() {
- return 'Conduct Polls';
+ return pht('Conduct Polls');
}
public function getTitleGlyph() {
diff --git a/src/applications/subscriptions/application/PhabricatorSubscriptionsApplication.php b/src/applications/subscriptions/application/PhabricatorSubscriptionsApplication.php
--- a/src/applications/subscriptions/application/PhabricatorSubscriptionsApplication.php
+++ b/src/applications/subscriptions/application/PhabricatorSubscriptionsApplication.php
@@ -2,6 +2,10 @@
final class PhabricatorSubscriptionsApplication extends PhabricatorApplication {
+ public function getName() {
+ return pht('Subscriptions');
+ }
+
public function isLaunchable() {
return false;
}
diff --git a/src/applications/support/application/PhabricatorSupportApplication.php b/src/applications/support/application/PhabricatorSupportApplication.php
--- a/src/applications/support/application/PhabricatorSupportApplication.php
+++ b/src/applications/support/application/PhabricatorSupportApplication.php
@@ -2,6 +2,10 @@
final class PhabricatorSupportApplication extends PhabricatorApplication {
+ public function getName() {
+ return pht('Support');
+ }
+
public function canUninstall() {
return false;
}
diff --git a/src/applications/system/application/PhabricatorSystemApplication.php b/src/applications/system/application/PhabricatorSystemApplication.php
--- a/src/applications/system/application/PhabricatorSystemApplication.php
+++ b/src/applications/system/application/PhabricatorSystemApplication.php
@@ -2,6 +2,10 @@
final class PhabricatorSystemApplication extends PhabricatorApplication {
+ public function getName() {
+ return pht('System');
+ }
+
public function canUninstall() {
return false;
}
diff --git a/src/applications/transactions/application/PhabricatorTransactionsApplication.php b/src/applications/transactions/application/PhabricatorTransactionsApplication.php
--- a/src/applications/transactions/application/PhabricatorTransactionsApplication.php
+++ b/src/applications/transactions/application/PhabricatorTransactionsApplication.php
@@ -2,6 +2,10 @@
final class PhabricatorTransactionsApplication extends PhabricatorApplication {
+ public function getName() {
+ return pht('Transactions');
+ }
+
public function isLaunchable() {
return false;
}
diff --git a/src/applications/typeahead/application/PhabricatorTypeaheadApplication.php b/src/applications/typeahead/application/PhabricatorTypeaheadApplication.php
--- a/src/applications/typeahead/application/PhabricatorTypeaheadApplication.php
+++ b/src/applications/typeahead/application/PhabricatorTypeaheadApplication.php
@@ -2,6 +2,10 @@
final class PhabricatorTypeaheadApplication extends PhabricatorApplication {
+ public function getName() {
+ return pht('Typeahead');
+ }
+
public function getRoutes() {
return array(
'/typeahead/' => array(
diff --git a/src/applications/uiexample/application/PhabricatorUIExamplesApplication.php b/src/applications/uiexample/application/PhabricatorUIExamplesApplication.php
--- a/src/applications/uiexample/application/PhabricatorUIExamplesApplication.php
+++ b/src/applications/uiexample/application/PhabricatorUIExamplesApplication.php
@@ -10,6 +10,10 @@
return pht('Developer UI Examples');
}
+ public function getName() {
+ return pht('UIExamples');
+ }
+
public function getIconName() {
return 'uiexamples';
}
diff --git a/src/applications/xhprof/application/PhabricatorXHProfApplication.php b/src/applications/xhprof/application/PhabricatorXHProfApplication.php
--- a/src/applications/xhprof/application/PhabricatorXHProfApplication.php
+++ b/src/applications/xhprof/application/PhabricatorXHProfApplication.php
@@ -6,6 +6,10 @@
return '/xhprof/';
}
+ public function getName() {
+ return pht('XHProf');
+ }
+
public function getShortDescription() {
return pht('PHP Profiling Tool');
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Mar 25, 10:13 PM (1 w, 2 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7223303
Default Alt Text
D10027.id24102.diff (22 KB)
Attached To
Mode
D10027: Implement the `getName` method in `PhabricatorApplication` subclasses
Attached
Detach File
Event Timeline
Log In to Comment