Created
August 4, 2017 19:08
-
-
Save agonzalezro/8843a07cdee4e15407364de5be8717ce to your computer and use it in GitHub Desktop.
This file contains hidden or 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
#!/bin/bash | |
image=$(mktemp) | |
gophers=$(http http://gopherize.me/gophers/recent/json|jq '.gophers') | |
length=$(echo $gophers|jq '. | length') | |
random=$(jot -r 1 1 $(($length-1))) | |
url=$(echo $gophers|jq ".[$random].url"|tr -d \") | |
http --output $image $url | |
convert $image -background white -flatten gopher.jpeg | |
jp2a gopher.jpeg |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment