aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README.markdown2
-rwxr-xr-xgames/aaf5
-rw-r--r--man/man6/aaf.618
3 files changed, 25 insertions, 0 deletions
diff --git a/README.markdown b/README.markdown
index 02d6a6ce..de51573b 100644
--- a/README.markdown
+++ b/README.markdown
@@ -333,6 +333,8 @@ Installed by the `install-bin` target:
There's some silly stuff in `install-games`:
+* `aaf(6)` gets a random [ASCII Art Farts](http://www.asciiartfarts.com/)
+ comic.
* `kvlt(6)` translates input to emulate a style of typing unique to black
metal communities on the internet.
* `rndn(6)` implements an esoteric random number generation algorithm.
diff --git a/games/aaf b/games/aaf
new file mode 100755
index 00000000..288edd2d
--- /dev/null
+++ b/games/aaf
@@ -0,0 +1,5 @@
+#!/bin/sh
+command -v curl >/dev/null || exit
+command -v pup >/dev/null || exit
+curl http://www.asciiartfarts.com/random.cgi |
+pup -p 'table[cellpadding]' pre text{}
diff --git a/man/man6/aaf.6 b/man/man6/aaf.6
new file mode 100644
index 00000000..bd3fdadb
--- /dev/null
+++ b/man/man6/aaf.6
@@ -0,0 +1,18 @@
+.TH AAF 6 "June 2016" "Manual page for aaf"
+.SH NAME
+.B aaf
+\- print a random ASCII Art Farts comic
+.SH USAGE
+.B aaf
+.SH DESCRIPTION
+.B aaf
+retrieves a random ASCII Art Farts[1] comic using curl(1), extracting it from
+the HTML with pup[2], and writes it to stdout.
+.SH SEE ALSO
+[1]: http://www.asciiartfarts.com/
+.br
+[2]: https://github.com/ericchiang/pup
+.br
+curl(1)
+.SH AUTHOR
+Tom Ryder <tom@sanctum.geek.nz>