Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit53aba3f

Browse files
committed
Merge branch '4.4'
* 4.4: Add missing versionadded directive. refs#11956 Added small section about default values
2 parents8cda918 +84c200a commit53aba3f

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

‎components/dotenv.rst‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,17 @@ Use environment variables in values by prefixing variables with ``$``:
145145
its value will depend on the ``DB_USER`` value defined in other files
146146
instead of the value defined in this file.
147147

148+
Define a default value in case the environment variable is not set:
149+
150+
..code-block::terminal
151+
152+
DB_USER=
153+
DB_PASS=${DB_USER:-root}pass # results in DB_PASS=rootpass
154+
155+
..versionadded::4.4
156+
157+
The support for default values has been introduced in Symfony 4.4.
158+
148159
Embed commands via ``$()`` (not supported on Windows):
149160

150161
..code-block::terminal

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp