Skip to content

Commit 677ce2c

Browse files
committed
Update synopsis for products command
1 parent 7608444 commit 677ce2c

File tree

1 file changed

+12
-7
lines changed

1 file changed

+12
-7
lines changed

includes/CLI.php

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -178,19 +178,24 @@ public static function coupons( $args, $assoc_args ) {
178178
}
179179

180180
WP_CLI::add_command( 'wc generate products', array( 'WC\SmoothGenerator\CLI', 'products' ), array(
181+
'shortdesc' => 'Generate products.',
181182
'synopsis' => array(
182183
array(
183-
'name' => 'amount',
184-
'type' => 'positional',
185-
'optional' => true,
186-
'default' => 100,
184+
'name' => 'amount',
185+
'type' => 'positional',
186+
'description' => 'The number of products to generate.',
187+
'optional' => true,
188+
'default' => 100,
187189
),
188190
array(
189-
'name' => 'type',
190-
'type' => 'assoc',
191-
'optional' => true,
191+
'name' => 'type',
192+
'type' => 'assoc',
193+
'description' => 'Specify one type of product to generate. Otherwise defaults to a mix.',
194+
'optional' => true,
195+
'options' => array( 'simple', 'variable' ),
192196
),
193197
),
198+
'longdesc' => "## EXAMPLES\n\nwc generate products 100\n\nwc generate products 10 --type=variable",
194199
) );
195200

196201
WP_CLI::add_command( 'wc generate orders', array( 'WC\SmoothGenerator\CLI', 'orders' ), array(

0 commit comments

Comments
 (0)