Skip to content

Commit 11d87ad

Browse files
weaverryanwouterj
authored andcommitted
Adding details about new recipes:update command
1 parent 9a31473 commit 11d87ad

File tree

3 files changed

+17
-19
lines changed

3 files changed

+17
-19
lines changed

.doctor-rst.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ whitelist:
8888
- '.. versionadded:: 1.11' # MakerBundle
8989
- '.. versionadded:: 1.3' # MakerBundle
9090
- '.. versionadded:: 1.8' # MakerBundle
91-
- '.. versionadded:: 1.6' # Flex in setup/upgrade_minor.rst
91+
- '.. versionadded:: 1.18' # Flex in setup/upgrade_minor.rst
9292
- '0 => 123' # assertion for var_dumper - components/var_dumper.rst
9393
- '1 => "foo"' # assertion for var_dumper - components/var_dumper.rst
9494
- '$var .= "Because of this `\xE9` octet (\\xE9),\n";'

performance.rst

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,10 +115,13 @@ You can configure PHP to use this preload file:
115115
116116
; php.ini
117117
opcache.preload=/path/to/project/config/preload.php
118-
118+
119119
; required for opcache.preload:
120120
opcache.preload_user=www-data
121121
122+
If this file is missing, run this command to update the Symfony Flex recipe:
123+
``composer recipes:update symfony/framework-bundle``.
124+
122125
.. _performance-configure-opcache:
123126

124127
Configure OPcache for Maximum Performance

setup/_update_recipes.rst.inc

Lines changed: 12 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -9,30 +9,25 @@ it's a good idea to keep your files in sync with the recipes.
99
Symfony Flex provides several commands to help upgrade your recipes. Be sure to
1010
commit any unrelated changes you're working on before starting:
1111

12-
.. versionadded:: 1.6
12+
.. versionadded:: 1.18
1313

14-
The recipes commands were introduced in Symfony Flex 1.6.
14+
The ``recipes:update`` command was introduced in Symfony Flex 1.18.
1515

1616
.. code-block:: terminal
1717

18+
# choose an outdated recipe to update
19+
$ composer recipes:update
20+
21+
# update a specific recipe
22+
$ composer recipes:update symfony/framework-bundle
23+
1824
# see a list of all installed recipes and which have updates available
1925
$ composer recipes
2026

2127
# see detailed information about a specific recipes
2228
$ composer recipes symfony/framework-bundle
2329

24-
# update a specific recipes
25-
$ composer recipes:install symfony/framework-bundle --force -v
26-
27-
The tricky part of this process is that the recipe "update" does not perform
28-
any intelligent "upgrading" of your code. Instead, **the updates process re-installs
29-
the latest version of the recipe** which means that **your custom code will be
30-
overridden completely**. After updating a recipe, you need to carefully choose
31-
which changes you want, and undo the rest.
32-
33-
.. admonition:: Screencast
34-
:class: screencast
35-
36-
For a detailed example, see the `SymfonyCasts Symfony 5 Upgrade Tutorial`_.
37-
38-
.. _`SymfonyCasts Symfony 5 Upgrade Tutorial`: https://symfonycasts.com/screencast/symfony5-upgrade
30+
The ``recipes:update`` command is smart: it looks at the difference between the
31+
recipe when you installed it and the latest version. It then creates a patch and
32+
applies it to your app. If there are any conflicts, you can resolve them like a
33+
normal ``git`` conflict and commit like normal.

0 commit comments

Comments
 (0)