summaryrefslogtreecommitdiffstats
path: root/wtf
diff options
context:
space:
mode:
authorsalo <salo@NetBSD.org>2003-02-06 15:17:01 +0000
committersalo <salo@NetBSD.org>2003-02-06 15:17:01 +0000
commitd2c9435f39bf3cf490a36374e2dabc08a9c3128b (patch)
tree0baf00e5bcb3a745bfd0465ae8566e2901bb14f0 /wtf
parent3961d5130729d5938bb51ec1204b2b61920720cb (diff)
downloadbsdgames-darwin-d2c9435f39bf3cf490a36374e2dabc08a9c3128b.tar.gz
bsdgames-darwin-d2c9435f39bf3cf490a36374e2dabc08a9c3128b.tar.zst
bsdgames-darwin-d2c9435f39bf3cf490a36374e2dabc08a9c3128b.zip
Use pipe ("|") as a sed command field separator and allow slash ("/")
character in acronyms. (e.g. W/, B/C, ...) Approved by jdolecek.
Diffstat (limited to 'wtf')
-rw-r--r--wtf/wtf4
1 files changed, 2 insertions, 2 deletions
diff --git a/wtf/wtf b/wtf/wtf
index b02ef364..92393e7c 100644
--- a/wtf/wtf
+++ b/wtf/wtf
@@ -1,6 +1,6 @@
#!/bin/sh
#
-# $NetBSD: wtf,v 1.7 2000/11/21 00:18:52 soren Exp $
+# $NetBSD: wtf,v 1.8 2003/02/06 15:17:01 salo Exp $
#
# Public domain
#
@@ -19,7 +19,7 @@ rv=0
while [ $# -gt 0 ] ; do
target=`echo $1 | tr '[a-z]' '[A-Z]'`
ans=`fgrep $target < $acronyms 2>/dev/null \
- | sed -ne "/^$target[[:space:]]/s/^$target[[:space:]]*//p"`
+ | sed -ne "\|^$target[[:space:]]|s|^$target[[:space:]]*||p"`
if [ "$ans" != "" ] ; then
echo "$target: $ans"
else