annotate paste/paste.26175 @ 10267:a63e04458b89

<b_jonas> slashlearn `hello//`hello prints variants of hello, world. To control format, pass a single letter as command-line argument. "@"=>"hello, world", "H"=>"hello, world.", P=>"hello, world!", "X"=>"hello, world,", take 1 letter later to s/h/H/, 2 letter later to s/d,/d/, 4 letter later to s/w/W/, lowercase to remove newline.
author HackBot
date Wed, 15 Feb 2017 02:13:17 +0000
parents e037173e0012
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
e037173e0012 Initial import.
HackBot
parents:
diff changeset
1 #!/bin/sh
e037173e0012 Initial import.
HackBot
parents:
diff changeset
2 topic=$(echo "$1" | tr A-Z a-z)
e037173e0012 Initial import.
HackBot
parents:
diff changeset
3 [ -e "wisdom/$topic" ] || { echo "$1? ¯\(°_o)/¯"; exit 1; }
e037173e0012 Initial import.
HackBot
parents:
diff changeset
4 cat "wisdom/$topic"
e037173e0012 Initial import.
HackBot
parents:
diff changeset
5