Unlink default configurations

Component ID

2389769

Component name

Unlink default configurations

Component type

module

Maintenance status

Development status

Component security advisory coverage

not-covered

Downloads

1854

Component created

Component changed

Component body

This modules provides possibility to move site configuration from files to database with just a couple clicks!

How often did you expirience a situation when module or distribution provides default views, rules, entities and other configurations out of the box which you had to change and then deploy it with Features? We know it was a hard time full of your tears and screams like "Drupal, why?"

With this module you can quickly unlink configurations from their file storage and move them directly to the database. So now you can change them with UI and then migrate with Features, just like they were created over the UI.

How does it work?

For site builders: it's a pure magic and noone can explain how it works.

For developers: it alters configurations stored in hook_defaults(). Then configs which should be moved to the database just get saved there and then unset from array of configs which stored in files.

Currently we successfully tested integration with the following modules:

  • Panels
  • Views
  • Rules
  • Mini panels
  • Display Suite
  • Relation
  • Path Breadcrumbs
  • Page Manager
  • Context Actions and Tabs

If you tested integration with other configurations and it works - we will appreciate if you inform us about that. Also our module provides possibility to integrate with any kind of exportable configuration (see README.txt), so you're very welcome to create a new issue and provide a patch.

Examples

Imagine that you use Commerce module and you want to change default view for line items, or you want to change default rules. In this case you need to install this module and then in the admin UI you should choose components which you want to overwrite. After this just change configurations which you wanted to change and add them to the features. And you need to add variable "unlink_defaults" to some feature as well (it is needed for every version of the site (local, dev, stage, live) to have same configuration for unlink default module). For adding variables to features you need use module Strongarm.

How to return configs back to file storage?

First step should be to uncheck your configs from configuration page of Unlink Default Config module. Then go to a list with configs (for example, for views it is /admin/structure/views) and click "Revert" link near name of your config. This process will remove config from database and automatically switch config storage back to files.

Similar modules

  • Feature Tools (with its unlink feature) - helps you to unlink configs from your features when they are already there.