OSDN Git Service

Support arbitrary filtering when listing terms
authorDaniel Bachhuber <d@danielbachhuber.com>
Thu, 29 Aug 2013 18:41:07 +0000 (11:41 -0700)
committerDaniel Bachhuber <d@danielbachhuber.com>
Thu, 29 Aug 2013 18:41:07 +0000 (11:41 -0700)
php/commands/term.php

index 4353957..415feb5 100644 (file)
@@ -23,6 +23,9 @@ class Term_Command extends WP_CLI_Command {
         *
         * <taxonomy>
         * : List terms of a given taxonomy.
+        *  
+        * --<field>=<value>
+        * : Filter by one or more fields. For accepted fields, see get_terms().
         *
         * --fields=<fields>
         * : Limit the output to specific object fields. Defaults to all of the term object fields.
@@ -37,7 +40,7 @@ class Term_Command extends WP_CLI_Command {
         *     wp term list post_tag --fields=name,slug
         *
         * @subcommand list
-        * @synopsis <taxonomy> [--fields=<fields>] [--format=<format>]
+        * @synopsis <taxonomy> [--<field>=<value>] [--fields=<fields>] [--format=<format>]
         */
        public function _list( $args, $assoc_args ) {