Created
March 4, 2016 20:50
-
-
Save infn8/be3edaa79aa40693983a to your computer and use it in GitHub Desktop.
WP CLI add post from lorem ipsum API with author of first administrator.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl "http://loripsum.net/api/5/medium/decorate/link/ul/ol/dl/bq/code/headers/" | sed "s/<\/p>/<\/p>\<\!\-\-more\-\-\>/" | wp post generate --post_content --count=1 --post_author=$(wp user list --role=administrator --field=ID --format=json | sed "s/\[//" | sed "s/\]//" | sed "s/\,.*//") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment