title: How to have environment specific .env files for dotenv (in Laravel 5)
body: <p>I've just started using Laravel 5 which uses the dotenv library. This uses a .env file in the root of the project which sets the environment with this line:</p>
  
  <pre><code>APP_ENV=local
  </code></pre>
  
  <p>According to everything I've read on the subject, all other environmental specific configuration should be placed in this file, so database passwords, urls etc, which are then read into the main config array like this:</p>
  
  <pre><code>env('DB_HOST', 'localhost')
  </code></pre>
  
  <p>While I feel this may work for a few specific things like database passwords that you might not want committed, what I really want is to be able to commit most or all of my different environmental values for each environment.</p>
  
  <p>Thus what I want is for .env to define APP_ENV as "local", "staging" or "production" and then have a .local.env or .env.local file containing the values, which I can then commit and the correct file will be loaded based on APP_ENV.</p>
  
  <p>Is this possible? Laravel 4 had the cascading config arrays which seemed a lot more flexible but if I can have an environmental .env file then I can live with that.</p>