Skip to content

Instantly share code, notes, and snippets.

@sareiodata
Created October 4, 2017 09:01
Show Gist options
  • Save sareiodata/3de4939c27be9f8d73d3aef48a763a1c to your computer and use it in GitHub Desktop.
Save sareiodata/3de4939c27be9f8d73d3aef48a763a1c to your computer and use it in GitHub Desktop.
<?php
/*
Plugin Name: Disable Specific Plugins in Dev - translatepress.com
Plugin URI: http://translatepress.com
Description: Disable specified plugins in development environment
Author: TranslatePress
Version: 1.1
Author URI: http://translatepress.com
*/
if ( site_url() !== 'https://translatepress.com' ) {
$plugins = array(
'backupbuddy/backupbuddy.php',
'wp-rocket/wp-rocket.php',
);
require_once(ABSPATH . 'wp-admin/includes/plugin.php');
deactivate_plugins($plugins);
/* Put Jetpack in development mode */
define( 'JETPACK_DEV_DEBUG', true);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment