Ejemplo n.º 1
0
         $args = array('help');
     } else {
         throw new ArcanistUsageException("No command provided. Try 'arc help'.");
     }
 } else {
     if ($help) {
         array_unshift($args, 'help');
     }
 }
 $configuration_manager = new ArcanistConfigurationManager();
 if ($custom_arcrc) {
     $configuration_manager->setUserConfigurationFileLocation($custom_arcrc);
 }
 $global_config = $configuration_manager->readUserArcConfig();
 $system_config = $configuration_manager->readSystemArcConfig();
 $runtime_config = $configuration_manager->applyRuntimeArcConfig($base_args);
 if ($skip_arcconfig) {
     $working_copy = ArcanistWorkingCopyIdentity::newDummyWorkingCopy();
 } else {
     $working_copy = ArcanistWorkingCopyIdentity::newFromPath($working_directory);
 }
 $configuration_manager->setWorkingCopyIdentity($working_copy);
 reenter_if_this_is_arcanist_or_libphutil($console, $working_copy, $original_argv);
 // Load additional libraries, which can provide new classes like configuration
 // overrides, linters and lint engines, unit test engines, etc.
 // If the user specified "--load-phutil-library" one or more times from
 // the command line, we load those libraries **instead** of whatever else
 // is configured. This is basically a debugging feature to let you force
 // specific libraries to load regardless of the state of the world.
 if ($load) {
     $console->writeLog("Using '--load-phutil-library' flag, configuration will be ignored " . "and configured libraries will not be loaded." . "\n");