@@ -30,9 +30,10 @@ important changes:
30
30
other environments. You can also create a ``.env.test `` file for test-environment
31
31
overrides.
32
32
33
- * E) If you pass the ``--env= `` flag when running ``bin/console ``, this value will
34
- override your ``APP_ENV `` environment variable (if set). And so, if you pass
35
- ``--env=prod ``, the DotEnv component *will * try to load your ``.env* `` files.
33
+ * E) `One further change to the recipe in January 2019 `_ means that your ``.env ``
34
+ files are *always * loaded, even if you set an ``APP_ENV=prod `` environment
35
+ variable. The purpose is for the ``.env `` files to define default values that
36
+ you can override if you want to with real environment values.
36
37
37
38
There are a few other improvements, but these are the most important. To take advantage
38
39
of these, you *will * need to modify a few files in your existing app.
@@ -52,7 +53,7 @@ changes can be made to any Symfony 3.4 or higher app:
52
53
file. If you've customized this file, make sure to keep those changes (but use
53
54
the rest of the changes).
54
55
55
- #. Update your `bin/console `_ (` bin/console diff `_) file to load the new ``config/bootstrap.php `` file.
56
+ #. Update your `bin/console `_ file to load the new ``config/bootstrap.php `` file.
56
57
57
58
#. Update ``.gitignore ``:
58
59
@@ -64,6 +65,7 @@ changes can be made to any Symfony 3.4 or higher app:
64
65
###> symfony/framework-bundle ###
65
66
- /.env
66
67
+ /.env.local
68
+ + /.env.local.php
67
69
+ /.env.*.local
68
70
69
71
# ...
@@ -90,7 +92,7 @@ changes can be made to any Symfony 3.4 or higher app:
90
92
.. _`public/index.php` : https://github.com/symfony/recipes/blob/master/symfony/framework-bundle/4.2/public/index.php
91
93
.. _`index.php diff` : https://github.com/symfony/recipes/compare/8a4e5555e30d5dff64275e2788a901f31a214e79...f54d6a468405d0d8d27b0e790dc09a01e337777a#diff-473fca613b5bda15d87731036cb31586
92
94
.. _`bin/console` : https://github.com/symfony/recipes/blob/master/symfony/console/3.3/bin/console
93
- .. _`bin/console diff` : https://github.com/symfony/recipes/compare/8a4e5555e30d5dff64275e2788a901f31a214e79...f54d6a468405d0d8d27b0e790dc09a01e337777a#diff-2af50efd729ff8e61dcbd936cf2b114b
94
95
.. _`comment on the top of .env` : https://github.com/symfony/recipes/blob/master/symfony/flex/1.0/.env
95
96
.. _`create a new .env.test` : https://github.com/symfony/recipes/blob/master/symfony/phpunit-bridge/3.3/.env.test
96
97
.. _`phpunit.xml.dist file` : https://github.com/symfony/recipes/blob/master/symfony/phpunit-bridge/3.3/phpunit.xml.dist
98
+ .. _`One further change to the recipe in January 2019` : https://github.com/symfony/recipes/pull/501
0 commit comments