OSDN Git Service

Switched from --keys-and-salts="..." option to --skip-salts based on @scribu and...
authorNikolay Kolev <nikolay@users.noreply.github.com>
Tue, 20 Aug 2013 01:37:42 +0000 (18:37 -0700)
committerNikolay Kolev <nikolay@users.noreply.github.com>
Tue, 20 Aug 2013 01:37:42 +0000 (18:37 -0700)
php/commands/core.php

index d26f0e0..988231c 100644 (file)
@@ -154,8 +154,8 @@ class Core_Command extends WP_CLI_Command {
         * --extra-php
         * : If set, the command reads additional PHP code from STDIN.
         * 
-        * --keys-and-salts
-        * : Use existing secrets versus generating afresh as the default behavior.
+        * --skip-salts
+        * : If set, keys and salts won't be generated, but, instead, should be passed via --extra-php.
         *
         * ## EXAMPLES
         *
@@ -168,7 +168,7 @@ class Core_Command extends WP_CLI_Command {
         *     define( 'WP_DEBUG_LOG', true );
         *     PHP
         *
-        * @synopsis --dbname=<name> --dbuser=<user> [--dbpass=<password>] [--dbhost=<host>] [--dbprefix=<prefix>] [--locale=<locale>] [--extra-php]
+        * @synopsis --dbname=<name> --dbuser=<user> [--dbpass=<password>] [--dbhost=<host>] [--dbprefix=<prefix>] [--locale=<locale>] [--extra-php] [--skip-satls]
         */
        public function config( $_, $assoc_args ) {
                if ( Utils\locate_wp_config() ) {
@@ -199,7 +199,7 @@ class Core_Command extends WP_CLI_Command {
                }
 
                // TODO: adapt more resilient code from wp-admin/setup-config.php
-               if ( ! isset( $assoc_args['keys-and-salts'] ) ) {
+               if ( ! isset( $assoc_args['skip-salts'] ) ) {
                        $assoc_args['keys-and-salts'] = self::_read(
                                'https://api.wordpress.org/secret-key/1.1/salt/' );
                }