Revert a Drupal feature during deployment
To revert a features module during deployment, add an update hook and call features_revert with the name of the module and the component you want to revert.
This will revert panels_mini in the features module called "my_module" when you run update.php
You can find the name of the components in the features .info file, as follows:
- features[component] = "name"
So for a mini panel called "my_mini_panel", the .info file would have this line:
- features[panels_mini] = "my_mini_panel"
Now once you have deployed your feature to a new server, you just need to run update.php. The feature will revert to its code version. You would do this if you have changed a feature in your development environment and re-exported to code.
Learn Drupal Features
Make your life easier by packaging up Drupal site building settings in Features modules. No coding required!
Free 5 day course where you will learn to create and update your own Drupal Feature module.