$root = Request::foundation()->getRootUrl(); $environment = Request::detect_env($environments, $root); } /* |-------------------------------------------------------------------------- | Set The Application Environment |-------------------------------------------------------------------------- | | Once we have determined the application environment, we will set it on | the global server array of the HttpFoundation request. This makes it | available throughout the application, thought it is mainly only | used to determine which configuration files to merge in. | */ if (isset($environment)) { Request::set_env($environment); } /* |-------------------------------------------------------------------------- | Set The CLI Options Array |-------------------------------------------------------------------------- | | If the current request is from the Artisan command-line interface, we | will parse the command line arguments and options and set them the | array of options in the $_SERVER global array for convenience. | */ if (defined('STDIN')) { $console = CLI\Command::options($_SERVER['argv']); list($arguments, $options) = $console; $options = array_change_key_case($options, CASE_UPPER);