Download the PHP package umpirsky/symfony-upgrade-fixer without Composer
On this page you can find all versions of the php package umpirsky/symfony-upgrade-fixer. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download umpirsky/symfony-upgrade-fixer
More information about umpirsky/symfony-upgrade-fixer
Files in umpirsky/symfony-upgrade-fixer
Package symfony-upgrade-fixer
Short Description Analyzes your Symfony project and tries to make it compatible with the new version of Symfony framework.
License MIT
Informations about the package symfony-upgrade-fixer
symfony upgrade fixer • twig gettext extractor • wisdom • centipede • permissions handler • extraload • gravatar • locurro • country list • transliterator
Symfony Upgrade Fixer
Analyzes your Symfony project and tries to make it compatible with the new version of Symfony framework.
Installation
Manual
Local
Download the symfony-upgrade-fixer.phar
file and store it somewhere on your computer.
Global
You can run these commands to easily access symfony-upgrade-fixer
from anywhere on
your system:
Then, just run symfony-upgrade-fixer
.
Composer
Local
Global
Make sure you have ~/.composer/vendor/bin
in your PATH
and
you're good to go:
Don't forget to add this line in your .bashrc
file if you want to keep this change after reboot.
Usage
The fix
command tries to fix as much upgrade issues as possible on a given file or directory:
The --dry-run
option displays the files that need to be fixed but without actually modifying them:
The --no-use-reorder
option prevents the fixer from re-ordering USE statements:
The --fixers
option allows to specify which fixers should be used:
Fixers available
Name | Description |
---|---|
form_configure_options | The method AbstractType::setDefaultOptions(OptionsResolverInterface $resolver) have been renamed to AbstractType::configureOptions(OptionsResolver $resolver). |
form_events | The events PRE_BIND, BIND and POST_BIND were renamed to PRE_SUBMIT, SUBMIT and POST_SUBMIT. |
form_getname_to_getblockprefix | The method FormTypeInterface::getName() was deprecated, you should now implement FormTypeInterface::getBlockPrefix() instead. |
form_option_names | Options precision and virtual was renamed to scale and inherit_data. |
form_parent_type | Returning type instances from FormTypeInterface::getParent() is deprecated, return the fully-qualified class name of the parent type class instead. |
form_type_names | Instead of referencing types by name, you should reference them by their fully-qualified class name (FQCN) instead. |
form_extension_get_extended_type | Instead of referencing extended types by name, you should reference them by their fully-qualified class name (FQCN) instead. |
get_request | The getRequest method of the base controller class was removed, request object is injected in the action method instead. |
inherit_data_aware_iterator | The class VirtualFormAwareIterator was renamed to InheritDataAwareIterator. |
progress_bar | ProgressHelper has been removed in favor of ProgressBar. |
property_access | Renamed PropertyAccess::getPropertyAccessor to PropertyAccess::createPropertyAccessor. |
Real Life Examples
It is tested against few cool Symfony projects:
Contribute
The tool is based on PHP Coding Standards Fixer and the contributing process is very similar. I see no sense in re-doing it so far.
If you want to contribute to README, please don't edit README.md
directly - it is autogenerated. Edit README.tpl
instead and run: