Mercurial > repo
comparison bin/learn @ 5040:66fb0dc90cb9
<oerjan> sed -i \'4c\\echo "Learned \'"\'"\'$topic\'"\'"\': $1"\' bin/learn
author | HackBot |
---|---|
date | Fri, 10 Oct 2014 11:28:33 +0000 |
parents | b3b11a73cd92 |
children |
comparison
equal
deleted
inserted
replaced
5039:74cae6b8f28c | 5040:66fb0dc90cb9 |
---|---|
1 #!/bin/bash | 1 #!/bin/bash |
2 topic=$(echo "$1" | lowercase | sed 's/^\(an\?\|the\) //;s/s\? .*//') | 2 topic=$(echo "$1" | lowercase | sed 's/^\(an\?\|the\) //;s/s\? .*//') |
3 echo "$1" >"wisdom/$topic" | 3 echo "$1" >"wisdom/$topic" |
4 echo "I knew that." | 4 echo "Learned '$topic': $1" |
5 | 5 |