@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Implement the `getName` method in `PhabricatorApplication` subclasses

Summary: Provide an implementation for the `getName` method rather than automagically determining the application name.

Test Plan: Saw reasonable application names in the launcher.

Reviewers: #blessed_reviewers, epriestley

Reviewed By: #blessed_reviewers, epriestley

Subscribers: epriestley, Korvin

Differential Revision: https://secure.phabricator.com/D10027

+169 -11
+4
src/applications/audit/application/PhabricatorAuditApplication.php
··· 10 10 return 'audit'; 11 11 } 12 12 13 + public function getName() { 14 + return pht('Audit'); 15 + } 16 + 13 17 public function getShortDescription() { 14 18 return pht('Browse and Audit Commits'); 15 19 }
+4
src/applications/auth/application/PhabricatorAuthApplication.php
··· 18 18 return $viewer->getIsAdmin(); 19 19 } 20 20 21 + public function getName() { 22 + return pht('Auth'); 23 + } 24 + 21 25 public function getShortDescription() { 22 26 return pht('Login/Registration'); 23 27 }
+7 -9
src/applications/base/PhabricatorApplication.php
··· 27 27 /* -( Application Information )-------------------------------------------- */ 28 28 29 29 30 + /** 31 + * TODO: This should be abstract, but is not for historical reasons. 32 + */ 30 33 public function getName() { 31 - 32 - // TODO: This is sort of gross. 34 + phutil_deprecated( 35 + 'Automatic naming of `PhabricatorApplication` classes.', 36 + 'You should override the `getName` method.'); 33 37 34 38 $match = null; 35 - 36 - $regex = '/^Phabricator([A-Z][a-zA-Z]*)Application$/'; 37 - if (preg_match($regex, get_class($this), $match)) { 38 - return $match[1]; 39 - } 40 - 41 39 $regex = '/^PhabricatorApplication([A-Z][a-zA-Z]*)$/'; 42 40 if (preg_match($regex, get_class($this), $match)) { 43 41 return $match[1]; 44 42 } 45 43 46 - throw new Exception('Unable to determine application name automagically.'); 44 + throw new PhutilMethodNotImplementedException(); 47 45 } 48 46 49 47 public function getShortDescription() {
+4
src/applications/base/controller/__tests__/PhabricatorTestApplication.php
··· 4 4 5 5 private $policies = array(); 6 6 7 + public function getName() { 8 + return pht('Test'); 9 + } 10 + 7 11 public function isUnlisted() { 8 12 return true; 9 13 }
+4
src/applications/calendar/application/PhabricatorCalendarApplication.php
··· 2 2 3 3 final class PhabricatorCalendarApplication extends PhabricatorApplication { 4 4 5 + public function getName() { 6 + return pht('Calendar'); 7 + } 8 + 5 9 public function getShortDescription() { 6 10 return pht('Upcoming Events'); 7 11 }
+4
src/applications/chatlog/application/PhabricatorChatLogApplication.php
··· 6 6 return '/chatlog/'; 7 7 } 8 8 9 + public function getName() { 10 + return pht('ChatLog'); 11 + } 12 + 9 13 public function getShortDescription() { 10 14 return pht('IRC Logs'); 11 15 }
+4
src/applications/conduit/application/PhabricatorConduitApplication.php
··· 18 18 return PhabricatorEnv::getDoclink('Conduit Technical Documentation'); 19 19 } 20 20 21 + public function getName() { 22 + return pht('Conduit'); 23 + } 24 + 21 25 public function getShortDescription() { 22 26 return pht('Developer API'); 23 27 }
+4
src/applications/config/application/PhabricatorConfigApplication.php
··· 26 26 return false; 27 27 } 28 28 29 + public function getName() { 30 + return 'Config'; 31 + } 32 + 29 33 public function getShortDescription() { 30 34 return pht('Configure Phabricator'); 31 35 }
+4
src/applications/conpherence/application/PhabricatorConpherenceApplication.php
··· 6 6 return '/conpherence/'; 7 7 } 8 8 9 + public function getName() { 10 + return pht('Conpherence'); 11 + } 12 + 9 13 public function getShortDescription() { 10 14 return pht('Send Messages'); 11 15 }
+4
src/applications/countdown/application/PhabricatorCountdownApplication.php
··· 10 10 return 'countdown'; 11 11 } 12 12 13 + public function getName() { 14 + return pht('Countdown'); 15 + } 16 + 13 17 public function getShortDescription() { 14 18 return pht('Countdown to Events'); 15 19 }
+4
src/applications/differential/application/PhabricatorDifferentialApplication.php
··· 6 6 return '/differential/'; 7 7 } 8 8 9 + public function getName() { 10 + return pht('Differential'); 11 + } 12 + 9 13 public function getShortDescription() { 10 14 return pht('Review Code'); 11 15 }
+4
src/applications/diffusion/application/PhabricatorDiffusionApplication.php
··· 2 2 3 3 final class PhabricatorDiffusionApplication extends PhabricatorApplication { 4 4 5 + public function getName() { 6 + return pht('Diffusion'); 7 + } 8 + 5 9 public function getShortDescription() { 6 10 return pht('Host and Browse Repositories'); 7 11 }
+4
src/applications/diviner/application/PhabricatorDivinerApplication.php
··· 10 10 return 'diviner'; 11 11 } 12 12 13 + public function getName() { 14 + return pht('Diviner'); 15 + } 16 + 13 17 public function getShortDescription() { 14 18 return pht('Documentation'); 15 19 }
+4
src/applications/doorkeeper/application/PhabricatorDoorkeeperApplication.php
··· 10 10 return false; 11 11 } 12 12 13 + public function getName() { 14 + return pht('Doorkeeper'); 15 + } 16 + 13 17 public function getShortDescription() { 14 18 return pht('Connect to Other Software'); 15 19 }
+4
src/applications/drydock/application/PhabricatorDrydockApplication.php
··· 6 6 return '/drydock/'; 7 7 } 8 8 9 + public function getName() { 10 + return pht('Drydock'); 11 + } 12 + 9 13 public function getShortDescription() { 10 14 return pht('Allocate Software Resources'); 11 15 }
+4
src/applications/feed/application/PhabricatorFeedApplication.php
··· 6 6 return '/feed/'; 7 7 } 8 8 9 + public function getName() { 10 + return pht('Feed'); 11 + } 12 + 9 13 public function getShortDescription() { 10 14 return pht('Review Recent Activity'); 11 15 }
+4
src/applications/files/application/PhabricatorFilesApplication.php
··· 6 6 return '/file/'; 7 7 } 8 8 9 + public function getName() { 10 + return pht('Files'); 11 + } 12 + 9 13 public function getShortDescription() { 10 14 return 'Store and Share Files'; 11 15 }
+4
src/applications/flag/application/PhabricatorFlagsApplication.php
··· 2 2 3 3 final class PhabricatorFlagsApplication extends PhabricatorApplication { 4 4 5 + public function getName() { 6 + return pht('Flags'); 7 + } 8 + 5 9 public function getShortDescription() { 6 10 return pht('Personal Bookmarks'); 7 11 }
+4
src/applications/harbormaster/application/PhabricatorHarbormasterApplication.php
··· 6 6 return '/harbormaster/'; 7 7 } 8 8 9 + public function getName() { 10 + return pht('Harbormaster'); 11 + } 12 + 9 13 public function getShortDescription() { 10 14 return pht('Build/CI'); 11 15 }
+4
src/applications/help/application/PhabricatorHelpApplication.php
··· 2 2 3 3 final class PhabricatorHelpApplication extends PhabricatorApplication { 4 4 5 + public function getName() { 6 + return pht('Help'); 7 + } 8 + 5 9 public function canUninstall() { 6 10 return false; 7 11 }
+4
src/applications/herald/application/PhabricatorHeraldApplication.php
··· 10 10 return 'herald'; 11 11 } 12 12 13 + public function getName() { 14 + return pht('Herald'); 15 + } 16 + 13 17 public function getShortDescription() { 14 18 return pht('Create Notification Rules'); 15 19 }
+4
src/applications/home/application/PhabricatorHomeApplication.php
··· 8 8 return '/home/'; 9 9 } 10 10 11 + public function getName() { 12 + return pht('Home'); 13 + } 14 + 11 15 public function getShortDescription() { 12 16 return pht('Command Center'); 13 17 }
+4
src/applications/legalpad/application/PhabricatorLegalpadApplication.php
··· 6 6 return '/legalpad/'; 7 7 } 8 8 9 + public function getName() { 10 + return pht('Legalpad'); 11 + } 12 + 9 13 public function getShortDescription() { 10 14 return pht('Agreements and Signatures'); 11 15 }
+4
src/applications/macro/application/PhabricatorMacroApplication.php
··· 6 6 return '/macro/'; 7 7 } 8 8 9 + public function getName() { 10 + return pht('Macro'); 11 + } 12 + 9 13 public function getShortDescription() { 10 14 return pht('Image Macros and Memes'); 11 15 }
+5 -1
src/applications/maniphest/application/PhabricatorManiphestApplication.php
··· 2 2 3 3 final class PhabricatorManiphestApplication extends PhabricatorApplication { 4 4 5 + public function getName() { 6 + return pht('Maniphest'); 7 + } 8 + 5 9 public function getShortDescription() { 6 - return 'Tasks and Bugs'; 10 + return pht('Tasks and Bugs'); 7 11 } 8 12 9 13 public function getBaseURI() {
+4
src/applications/meta/application/PhabricatorApplicationsApplication.php
··· 2 2 3 3 final class PhabricatorApplicationsApplication extends PhabricatorApplication { 4 4 5 + public function getName() { 6 + return pht('Applications'); 7 + } 8 + 5 9 public function canUninstall() { 6 10 return false; 7 11 }
+4
src/applications/people/application/PhabricatorPeopleApplication.php
··· 2 2 3 3 final class PhabricatorPeopleApplication extends PhabricatorApplication { 4 4 5 + public function getName() { 6 + return pht('People'); 7 + } 8 + 5 9 public function getShortDescription() { 6 10 return pht('User Accounts and Profiles'); 7 11 }
+4
src/applications/phrequent/application/PhabricatorPhrequentApplication.php
··· 2 2 3 3 final class PhabricatorPhrequentApplication extends PhabricatorApplication { 4 4 5 + public function getName() { 6 + return pht('Phrequent'); 7 + } 8 + 5 9 public function getShortDescription() { 6 10 return pht('Track Time Spent'); 7 11 }
+4
src/applications/phriction/application/PhabricatorPhrictionApplication.php
··· 2 2 3 3 final class PhabricatorPhrictionApplication extends PhabricatorApplication { 4 4 5 + public function getName() { 6 + return pht('Phriction'); 7 + } 8 + 5 9 public function getShortDescription() { 6 10 return pht('Wiki'); 7 11 }
+4
src/applications/policy/application/PhabricatorPolicyApplication.php
··· 2 2 3 3 final class PhabricatorPolicyApplication extends PhabricatorApplication { 4 4 5 + public function getName() { 6 + return pht('Policy'); 7 + } 8 + 5 9 public function isLaunchable() { 6 10 return false; 7 11 }
+4
src/applications/ponder/application/PhabricatorPonderApplication.php
··· 6 6 return '/ponder/'; 7 7 } 8 8 9 + public function getName() { 10 + return pht('Ponder'); 11 + } 12 + 9 13 public function getShortDescription() { 10 14 return pht('Questions and Answers'); 11 15 }
+4
src/applications/repository/application/PhabricatorRepositoriesApplication.php
··· 10 10 return 'repositories'; 11 11 } 12 12 13 + public function getName() { 14 + return pht('Repositories'); 15 + } 16 + 13 17 public function getShortDescription() { 14 18 return pht('(Deprecated)'); 15 19 }
+4
src/applications/settings/application/PhabricatorSettingsApplication.php
··· 6 6 return '/settings/'; 7 7 } 8 8 9 + public function getName() { 10 + return pht('Settings'); 11 + } 12 + 9 13 public function getShortDescription() { 10 14 return pht('User Preferences'); 11 15 }
+5 -1
src/applications/slowvote/application/PhabricatorSlowvoteApplication.php
··· 10 10 return 'slowvote'; 11 11 } 12 12 13 + public function getName() { 14 + return pht('Slowvote'); 15 + } 16 + 13 17 public function getShortDescription() { 14 - return 'Conduct Polls'; 18 + return pht('Conduct Polls'); 15 19 } 16 20 17 21 public function getTitleGlyph() {
+4
src/applications/subscriptions/application/PhabricatorSubscriptionsApplication.php
··· 2 2 3 3 final class PhabricatorSubscriptionsApplication extends PhabricatorApplication { 4 4 5 + public function getName() { 6 + return pht('Subscriptions'); 7 + } 8 + 5 9 public function isLaunchable() { 6 10 return false; 7 11 }
+4
src/applications/support/application/PhabricatorSupportApplication.php
··· 2 2 3 3 final class PhabricatorSupportApplication extends PhabricatorApplication { 4 4 5 + public function getName() { 6 + return pht('Support'); 7 + } 8 + 5 9 public function canUninstall() { 6 10 return false; 7 11 }
+4
src/applications/system/application/PhabricatorSystemApplication.php
··· 2 2 3 3 final class PhabricatorSystemApplication extends PhabricatorApplication { 4 4 5 + public function getName() { 6 + return pht('System'); 7 + } 8 + 5 9 public function canUninstall() { 6 10 return false; 7 11 }
+4
src/applications/transactions/application/PhabricatorTransactionsApplication.php
··· 2 2 3 3 final class PhabricatorTransactionsApplication extends PhabricatorApplication { 4 4 5 + public function getName() { 6 + return pht('Transactions'); 7 + } 8 + 5 9 public function isLaunchable() { 6 10 return false; 7 11 }
+4
src/applications/typeahead/application/PhabricatorTypeaheadApplication.php
··· 2 2 3 3 final class PhabricatorTypeaheadApplication extends PhabricatorApplication { 4 4 5 + public function getName() { 6 + return pht('Typeahead'); 7 + } 8 + 5 9 public function getRoutes() { 6 10 return array( 7 11 '/typeahead/' => array(
+4
src/applications/uiexample/application/PhabricatorUIExamplesApplication.php
··· 10 10 return pht('Developer UI Examples'); 11 11 } 12 12 13 + public function getName() { 14 + return pht('UIExamples'); 15 + } 16 + 13 17 public function getIconName() { 14 18 return 'uiexamples'; 15 19 }
+4
src/applications/xhprof/application/PhabricatorXHProfApplication.php
··· 6 6 return '/xhprof/'; 7 7 } 8 8 9 + public function getName() { 10 + return pht('XHProf'); 11 + } 12 + 9 13 public function getShortDescription() { 10 14 return pht('PHP Profiling Tool'); 11 15 }