forked from typisttech/image-optimize-command
-
Notifications
You must be signed in to change notification settings - Fork 0
/
command.php
37 lines (29 loc) · 1.59 KB
/
command.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<?php
declare(strict_types=1);
namespace TypistTech\ImageOptimizeCommand;
use TypistTech\ImageOptimizeCommand\CLI\Commands\AttachmentCommand;
use TypistTech\ImageOptimizeCommand\CLI\Commands\BatchCommand;
use TypistTech\ImageOptimizeCommand\CLI\Commands\CommandNamespace;
use TypistTech\ImageOptimizeCommand\CLI\Commands\FindCommand;
use TypistTech\ImageOptimizeCommand\CLI\Commands\MUPluginsCommand;
use TypistTech\ImageOptimizeCommand\CLI\Commands\PluginsCommand;
use TypistTech\ImageOptimizeCommand\CLI\Commands\ResetCommand;
use TypistTech\ImageOptimizeCommand\CLI\Commands\RestoreCommand;
use TypistTech\ImageOptimizeCommand\CLI\Commands\ThemesCommand;
use TypistTech\ImageOptimizeCommand\CLI\Commands\WPAdminCommand;
use TypistTech\ImageOptimizeCommand\CLI\Commands\WPIncludesCommand;
use WP_CLI;
if (! class_exists('WP_CLI')) {
return;
}
WP_CLI::add_command('image-optimize', CommandNamespace::class);
WP_CLI::add_command('image-optimize attachment', AttachmentCommand::class);
WP_CLI::add_command('image-optimize batch', BatchCommand::class);
WP_CLI::add_command('image-optimize restore', RestoreCommand::class);
WP_CLI::add_command('image-optimize reset', ResetCommand::class);
WP_CLI::add_command('image-optimize find', FindCommand::class);
WP_CLI::add_command('image-optimize mu-plugins', MUPluginsCommand::class);
WP_CLI::add_command('image-optimize plugins', PluginsCommand::class);
WP_CLI::add_command('image-optimize themes', ThemesCommand::class);
WP_CLI::add_command('image-optimize wp-admin', WPAdminCommand::class);
WP_CLI::add_command('image-optimize wp-includes', WPIncludesCommand::class);