[wp-trac] [WordPress Trac] #34936: Reconcile wp-settings-cli.php with wp-settings.php
WordPress Trac
noreply at wordpress.org
Sun Apr 17 13:18:10 UTC 2016
#34936: Reconcile wp-settings-cli.php with wp-settings.php
---------------------------------+------------------
Reporter: danielbachhuber | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: 4.6
Component: Bootstrap/Load | Version:
Severity: normal | Resolution:
Keywords: dev-feedback wp-cli | Focuses:
---------------------------------+------------------
Comment (by danielbachhuber):
> It could be worth trying the filtering approach. It looks like WordPress
is smart enough not to stomp `$wp_filter` if it's already defined before
`wp-includes/plugin.php`, so WP-CLI could inject its callbacks on the
global.
One problem with this approach is that it's a breaking change to WP-CLI's
current behavior. WP-CLI currently supports checking to see whether a
plugin is active, while skipping the loading of one or more plugins.
==== Before ====
{{{
$ wp plugin status wp-api --skip-plugins=wp-api
Plugin wp-api details:
Name: WP REST API
Status: Active
Version: 2.0-beta13
Author: WP REST API Team
Description: JSON-based REST API for WordPress, originally developed
as part of GSoC 2013.
}}}
==== After ====
{{{
$ wp plugin status wp-api --skip-plugins=wp-api
Plugin wp-api details:
Name: WP REST API
Status: Inactive
Version: 2.0-beta13
Author: WP REST API Team
Description: JSON-based REST API for WordPress, originally developed
as part of GSoC 2013.
}}}
Could we add late filters to `wp_get_active_network_plugins()` and
`wp_get_active_and_valid_plugins()` ?
--
Ticket URL: <https://core.trac.wordpress.org/ticket/34936#comment:6>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list