I'm trying to export a custom menu and I'm not seeing where the configuration for the menu is being exported to. I see no errors using the UI and the Drush commands appear to be working as they should, but no file is being created. How do we get these exported menu files?

Thanks in advance!!

Comments

deaconblues created an issue. See original summary.

timKruijsen’s picture

They go into your configuration. So you will first need to export your configuration before you will actually see any new files being generated.

fidovdbos’s picture

@deaconblues has this solve this issue ? If this solved your issue can you please close the issue ?

itamair’s picture

Priority: Normal » Major

I have this same issue too. Exactly how described by @deaconblues, with with GUI and Drush commands.
Nothing written anywhere ... (with configurations already exported in the $config_directories['sync'] folder)

itamair’s picture

Actually I have been able to save the structure_sync.data.yml file to my config sync folder.
It's tricky ... and came out after an uncertain sequence of export and Import ...
I think there is at least an evident lack of documentation on this module functionality.
Also which "safely", "full" and "force" do mean and which is the difference among them is not that clear (to me), and seem not to be documented anywhere ... isn't it?

benjaminbradley’s picture

Category: Bug report » Support request
Status: Active » Needs review

I ran into this as well. It's actually a 2-step process:

1. drush export-all
This moves the content from their respective database tables (for blocks, menus, terms) into the structure_sync.data configuration entry (still in the database).

2. drush config-export
This exports all the configuration entries from the database to files on disk.

maboresev’s picture

Hi everyone,

That @benjaminbradley said is the correct process to export. To import this content, is similar:

1- drush config-import (cim)
2- drush import-all (ia)

I wrote about this module about two months ago here (I wrote it in Spanish).

Also, I think that this issue should be 'Active', because it has no patch applied.

fidovdbos’s picture

Status: Needs review » Active
kuba-orlik’s picture

From what I understand this module saves the menu links into *database config* when I run drush export-menus, and in order to have those exported menus in version-controlled files I need to run drush config-export

fidovdbos’s picture

@kuba-orlik yes that's correct

texas-bronius’s picture

Status: Active » Closed (works as designed)

I'll take the liberty of closing this years-old issue as "works as designed" with the solid understanding how to export provided by @benjaminbradley in #6 and how to import by @maboresev in #7.

I'll dangle a comment here, too, that the same is not apparent how to do all this in admin UI:

- First Export per the module's admin interface: Admin > Structure Sync > Export whatever you're wanting to export
- Then get the config: Admin > Configuration > Development > Configuration Synchronization > Export
-- Try: Select "Single Item"
-- Select "Simple Configuration"
-- Select "structure_sync.data"

I presume the same goes for importing by UI: First import config then Import respective structures.

kay_v’s picture

this issue relates to need for documentation in progress at #3384297: where is the export directory?

I'm cross referencing since the discussion here exposes a common misunderstanding that documentation could clear up