-
-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Different way for updating flex projects #9962
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
.. index:: | ||
single: Upgrading; Minor Version | ||
|
||
Upgrading a Minor Version (e.g. 3.3.3 to 3.4.0) | ||
Upgrading a Minor Version (e.g. 4.0.0 to 4.1.0) | ||
=============================================== | ||
|
||
If you're upgrading a minor version (where the middle number changes), then | ||
|
@@ -21,16 +21,26 @@ There are two steps to upgrading a minor version: | |
1) Update the Symfony Library via Composer | ||
------------------------------------------ | ||
|
||
First, you need to update Symfony by modifying your ``composer.json`` file | ||
to use the new version: | ||
First, you need to update all Symfony packages by modifying your ``composer.json`` file | ||
to use the new version (the list of packages may vary depending on what you've installed): | ||
|
||
.. code-block:: json | ||
|
||
{ | ||
"...": "...", | ||
|
||
"require": { | ||
"symfony/symfony": "3.4.*", | ||
"symfony/asset": "^4.1", | ||
"symfony/console": "^4.1", | ||
"symfony/expression-language": "^4.1", | ||
"symfony/form": "^4.1", | ||
"symfony/framework-bundle": "^4.1", | ||
"symfony/process": "^4.1", | ||
"symfony/security-bundle": "^4.1", | ||
"symfony/twig-bundle": "^4.1", | ||
"symfony/validator": "^4.1", | ||
"symfony/web-link": "^4.1", | ||
"symfony/yaml": "^4.1" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Because all dependencies will now use the
|
||
}, | ||
"...": "...", | ||
} | ||
|
@@ -39,7 +49,7 @@ Next, use Composer to download new versions of the libraries: | |
|
||
.. code-block:: terminal | ||
|
||
$ composer update symfony/symfony | ||
$ composer update "symfony/*" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Add |
||
|
||
.. include:: /setup/_update_dep_errors.rst.inc | ||
|
||
|
@@ -55,12 +65,12 @@ to your code to get everything working. Additionally, some features you're | |
using might still work, but might now be deprecated. While that's just fine, | ||
if you know about these deprecations, you can start to fix them over time. | ||
|
||
Every version of Symfony comes with an UPGRADE file (e.g. `UPGRADE-3.4.md`_) | ||
Every version of Symfony comes with an UPGRADE file (e.g. `UPGRADE-4.1.md`_) | ||
included in the Symfony directory that describes these changes. If you follow | ||
the instructions in the document and update your code accordingly, it should be | ||
safe to update in the future. | ||
|
||
These documents can also be found in the `Symfony Repository`_. | ||
|
||
.. _`Symfony Repository`: https://github.com/symfony/symfony | ||
.. _`UPGRADE-3.4.md`: https://github.com/symfony/symfony/blob/3.4/UPGRADE-3.4.md | ||
.. _`UPGRADE-4.1.md`: https://github.com/symfony/symfony/blob/4.1/UPGRADE-4.1.md |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
.. index:: | ||
single: Upgrading; Patch Version | ||
|
||
Upgrading a Patch Version (e.g. 3.3.2 to 3.3.3) | ||
Upgrading a Patch Version (e.g. 4.1.0 to 4.1.1) | ||
=============================================== | ||
|
||
When a new patch version is released (only the last number changed), it is a | ||
|
@@ -10,12 +10,12 @@ version is *really* easy: | |
|
||
.. code-block:: terminal | ||
|
||
$ composer update symfony/symfony | ||
$ composer update "symfony/*" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Add |
||
|
||
That's it! You should not encounter any backwards-compatibility breaks or | ||
need to change anything else in your code. That's because when you started | ||
your project, your ``composer.json`` included Symfony using a constraint | ||
like ``3.3.*``, where only the *last* version number will change when you | ||
like ``^4.1``, where only the *last* version number will change when you | ||
update. | ||
|
||
.. tip:: | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In Composer 1.6, apparently there is a
--with-all-dependencies
. This looks like what we want.But then, because this new flag works the way we want it to, the user should never have version constraint problems anymore. So, we can add this flag to the other commands, then probably remove this section.