Skip to content

Commit

Permalink
[dotenv:init] Add .env dependency message. (#3818)
Browse files Browse the repository at this point in the history
  • Loading branch information
jmolivas authored Mar 6, 2018
1 parent e66605e commit f60afb6
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions templates/files/settings.dist
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@

// If not using real environment variables.
// Make sure you add the `vlucas/phpdotenv` dependency using composer:
// composer require vlucas/phpdoten
/**
// Load .env file if exists
if (file_exists(dirname(DRUPAL_ROOT) . '/.env')) {
// Load environment
// make sure you add the vlucas/phpdotenv dependency using:
// composer require vlucas/phpdotenv
$dotenv = new \Dotenv\Dotenv(dirname(DRUPAL_ROOT));
$dotenv->load();
}
*/

# Load environment
$env = getenv('ENVIRONMENT');
Expand Down

0 comments on commit f60afb6

Please sign in to comment.