git.slaskete.net
/
einar-bin
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
The ugly oneliner version of the imgur game
[einar-bin]
/
imgurgame-oneliner.bash
diff --git a/imgurgame-oneliner.bash
b/imgurgame-oneliner.bash
new file mode 100644
(file)
index 0000000..
a95705c
--- /dev/null
+++ b/
imgurgame-oneliner.bash
@@ -0,0
+1
@@
+while true; do url=http://i.imgur.com/$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 5 | head -n 1).jpg;if [[ $(curl -s -o /dev/null -I -w "%{http_code}" ${url}) == "200" ]]; then echo "Found ${url}"; fi; done