diff --git a/conf/default.conf.php b/conf/default.conf.php index d06ab7f571..e7e64829ac 100644 --- a/conf/default.conf.php +++ b/conf/default.conf.php @@ -1018,10 +1018,6 @@ return array( // "phd debug" are always launched in trace mdoe. See also 'phd.verbose'. 'phd.trace' => false, - // Path to custom celerity resource map relative to 'phabricator/src'. - // See also `scripts/celerity_mapper.php`. - 'celerity.resource-path' => '__celerity_resource_map__.php', - // This value is an input to the hash function when building resource hashes. // It has no security value, but if you accidentally poison user caches (by // pushing a bad patch or having something go wrong with a CDN, e.g.) you can diff --git a/scripts/celerity_mapper.php b/scripts/celerity_mapper.php index a8281252be..f462133891 100755 --- a/scripts/celerity_mapper.php +++ b/scripts/celerity_mapper.php @@ -189,17 +189,6 @@ $args->setSynopsis( "**celerity_mapper.php** [--output __path__] [--with-custom] "); $args->parse( array( - array( - 'name' => 'output', - 'param' => 'path', - 'default' => '../src/__celerity_resource_map__.php', - 'help' => "Set the path for resource map. It is usually useful for ". - "'celerity.resource-path' configuration.", - ), - array( - 'name' => 'with-custom', - 'help' => 'Include resources in /rsrc/custom/.', - ), array( 'name' => 'webroot', 'wildcard' => true, @@ -212,8 +201,9 @@ if (count($root) != 1 || !is_dir(reset($root))) { } $root = Filesystem::resolvePath(reset($root)); -$celerity_path = Filesystem::resolvePath($args->getArg('output'), $root); -$with_custom = $args->getArg('with-custom'); +$celerity_path = Filesystem::resolvePath( + '../src/__celerity_resource_map__.php', + $root); $resource_hash = PhabricatorEnv::getEnvConfig('celerity.resource-hash'); $runtime_map = array(); @@ -227,9 +217,6 @@ $finder = id(new FileFinder($root)) ->withSuffix('swf') ->withFollowSymlinks(true) ->setGenerateChecksums(true); -if (!$with_custom) { - $finder->excludePath('./rsrc/custom'); -} $raw_files = $finder->find(); echo "Processing ".count($raw_files)." files"; @@ -261,9 +248,6 @@ $finder = id(new FileFinder($root)) ->withSuffix('css') ->withFollowSymlinks(true) ->setGenerateChecksums(true); -if (!$with_custom) { - $finder->excludePath('./rsrc/custom'); -} $files = $finder->find(); echo "Processing ".count($files)." files"; diff --git a/src/applications/config/check/PhabricatorSetupCheckExtraConfig.php b/src/applications/config/check/PhabricatorSetupCheckExtraConfig.php index 0cb174e888..5e135c080f 100644 --- a/src/applications/config/check/PhabricatorSetupCheckExtraConfig.php +++ b/src/applications/config/check/PhabricatorSetupCheckExtraConfig.php @@ -167,6 +167,9 @@ final class PhabricatorSetupCheckExtraConfig extends PhabricatorSetupCheck { 'differential.anonymous-access' => pht( 'Phabricator now has meaningful global access controls. See '. '`policy.allow-public`.'), + 'celerity.resource-path' => pht( + 'An alternate resource map is no longer supported. Instead, use '. + 'multiple maps. See T4222.'), ); return $ancient_config; diff --git a/src/applications/config/option/PhabricatorExtendingPhabricatorConfigOptions.php b/src/applications/config/option/PhabricatorExtendingPhabricatorConfigOptions.php index 0b5b33b577..aa8ea620f6 100644 --- a/src/applications/config/option/PhabricatorExtendingPhabricatorConfigOptions.php +++ b/src/applications/config/option/PhabricatorExtendingPhabricatorConfigOptions.php @@ -28,18 +28,6 @@ final class PhabricatorExtendingPhabricatorConfigOptions "occur. Specify a list of classes which extend ". "PhabricatorEventListener here.")) ->addExample('MyEventListener', pht('Valid Setting')), - $this->newOption( - 'celerity.resource-path', - 'string', - '__celerity_resource_map__.php') - ->setLocked(true) - ->setSummary( - pht("Custom celerity resource map.")) - ->setDescription( - pht( - "Path to custom celerity resource map relative to ". - "'phabricator/src'. See also `scripts/celerity_mapper.php`.")) - ->addExample('local/my_celerity_map.php', pht('Valid Setting')), $this->newOption( 'aphront.default-application-configuration-class', 'class', diff --git a/src/infrastructure/celerity/CelerityResourceMap.php b/src/infrastructure/celerity/CelerityResourceMap.php index 9157729b75..9137a0f433 100644 --- a/src/infrastructure/celerity/CelerityResourceMap.php +++ b/src/infrastructure/celerity/CelerityResourceMap.php @@ -20,12 +20,11 @@ final class CelerityResourceMap { self::$instance = new CelerityResourceMap(); $root = phutil_get_library_root('phabricator'); - $path = PhabricatorEnv::getEnvConfig('celerity.resource-path'); + $path = '__celerity_resource_map__.php'; $ok = include_once $root.'/'.$path; if (!$ok) { throw new Exception( - "Failed to load Celerity resource map! Check the ". - "'celerity.resource-path' setting in your configuration."); + "Failed to load Celerity resource map!"); } } return self::$instance;