[wp-trac] [WordPress Trac] #9757: Allow Plugin/Theme updates from a uploaded .zip file.
WordPress Trac
noreply at wordpress.org
Fri Sep 8 19:27:09 UTC 2017
#9757: Allow Plugin/Theme updates from a uploaded .zip file.
--------------------------------------------------+------------------
Reporter: hakre | Owner:
Type: feature request | Status: new
Priority: low | Milestone: 4.9
Component: Upgrade/Install | Version: 2.8
Severity: normal | Resolution:
Keywords: dev-feedback has-patch needs-refresh | Focuses:
--------------------------------------------------+------------------
Comment (by psykro):
Right, first attempt at suggesting a possible way forward. To my mind, the
simplest way would be to check the zip being installed against any
existing possible matches, before the actual file is uploaded.
[[Image(https://jonathanbossenger.com/wp-content/uploads/2017/09/Add-
Plugins-Step-2-Confirmation.png)]]
So on adding a new plugin and clicking the Install Now button
1. Make a WP Rest API call to check if a plugin with either a full or
partial slug match exists
1. Display the 'This plugin you are attempting to install seems to exist'
message to the user
1. Display the matching plugin details (name, description and version
number)
1. Move the Install Now button under the 'confirmation' message and change
it to 'Accept and install'
1. On clicking the install button the usual upload and install process
proceeds
Things to consider
1. During the upgrade process, the plugin being overridden should probably
be renamed/moved to a temporary location, in case the plugin install fails
and a rollback is required (sometime like rename to _plugin_name
1. Once the new plugin has successfully been installed, clean up the
temporary location at step 1 above.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/9757#comment:73>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list