Skip to content

Instantly share code, notes, and snippets.

@Mombuyish
Created February 23, 2020 09:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Mombuyish/ad7c335efa6f4c7f8d2c10baff795c83 to your computer and use it in GitHub Desktop.
Save Mombuyish/ad7c335efa6f4c7f8d2c10baff795c83 to your computer and use it in GitHub Desktop.
<?php
protected function getFreshConfiguration()
{
$app = require $this->laravel->bootstrapPath().'/app.php'; // require application kernel of laravel.
$app->useStoragePath($this->laravel->storagePath()); // storage path.
$app->make(ConsoleKernelContract::class)->bootstrap(); // bootstraping instanced of ConsoleKernelContract class.
return $app['config']->all(); // get all of config variables.
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment