wp-cli / ideas

💡 Ideas and feature requests are collected here
40 stars 1 forks source link

DB & Media migration #14

Open Horttcore opened 7 years ago

Horttcore commented 7 years ago

Import the database from a remote installation into a local one and replace the url correctly ( as wp-search-replace does it)

ie: wp remote pull staging wp remote push prodcution

the environments would be defined in wp-cli config file.

Media should be handled the same ie compare which media is not used anymore and which media is missing and download them.

tldr; a wp cli alternate to wp migrate db pro plugin

danielbachhuber commented 7 years ago

Related #5

miya0001 commented 7 years ago

I am using Wordmove and it works fine for me. If it will be used as reference.

https://github.com/welaika/wordmove

schlessera commented 6 years ago

The DB part can already be done with existing commands by having search-replace export the modified SQL and piping it across aliases:

wp @staging search-replace <old-url> <new-url> --export | wp @production db import -