Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions code_samples/data_migration/examples/delete_content.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
-
type: content
mode: delete
match:
field: content_remote_id
value: __REMOTE_ID__
only_visible_content: true # Optional, default: true. If set to true, only visible content will be deleted.
allow_no_delete: false # Optional, default: false. If set to true, the migration will not fail if no content is found using the specified criteria.
6 changes: 6 additions & 0 deletions docs/content_management/data_migration/importing_data.md
Original file line number Diff line number Diff line change
Expand Up @@ -242,6 +242,12 @@ In this case you assign the `parent_folder_location_id` reference name to the lo
[[= include_file('code_samples/data_migration/examples/create_parent_and_child_content.yaml') =]]
```

Use the `delete` mode to delete content items:

``` yaml
[[= include_file('code_samples/data_migration/examples/delete_content.yaml') =]]
```

### Images

The following example shows how to migrate an `example-image.png` located in `public/var/site/storage/images/3/8/3/0/383-1-eng-GB` without manually placing it in the appropriate path.
Expand Down
Loading