Add the import feature to the "plesk ext wp-toolkit --wp-cli" utility
There is an export option for the "plesk ext wp-toolkit --wp-cli":
plesk ext wp-toolkit --wp-cli -instance-id 2 -- export
Starting export process...
Writing to file /var/www/vhosts/example.com/httpdocs/futureinvestments.wordpress.2022-06-03.000.xml
Success: All done with export.
But the import feature require native "wp" utility to be installed, and fails via plesk utility with error:
WordPress Importer needs to be installed. Try 'wp plugin install wordpress-importer --activate'.
Such option (import) in plesk ext wp-toolkit --wp-cli would improve usability
Thank you for your input! We will consider this functionality in upcoming releases if it is popular. Everyone, please continue voting for this feature if you consider it important.
--
IG
-
Evgeny commented
wp import command requires that https://wordpress.org/plugins/wordpress-importer/ this plugin should be installed for working properly.
This command doesn't require native wp, "Try 'wp plugin install wordpress-importer --activate'." is just a hardcoded tip.
https://github.com/wp-cli/import-command/blob/master/src/Import_Command.php#L309It would be unexpected if the command implicitly installed this plugin.
If the plugin is already installed, as a workaround, you can try to add an additional argument:
plesk ext wp-toolkit --wp-cli -instance-id 2 -- import #FILE# --skip-plugins=false