How do I pass an array as an argument to a WP-CLI command?
This is probably impossible since WP-CLI pass the arguments directly to wp_insert_posts. I’m automating this with wp eval. For example: wp eval ‘wp_set_object_terms(12 , array(1, 2, 3), “course”);’ The post id can be obtained when you create the post with –porcelain: wp post create … –porcelain Or by normal query with post title: wp eval … Read more