aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/index/see.prep
diff options
context:
space:
mode:
Diffstat (limited to 'src/cmd/index/see.prep')
-rw-r--r--src/cmd/index/see.prep10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/cmd/index/see.prep b/src/cmd/index/see.prep
new file mode 100644
index 00000000..33d4c2df
--- /dev/null
+++ b/src/cmd/index/see.prep
@@ -0,0 +1,10 @@
+#!/bin/sh
+
+awk ' # see.prep
+# Input: string "\t" string
+# Output: string "\t{see [also]} " string
+
+BEGIN { FS = "\t" }
+$3 ~ /%also/ { print $1 "\t{see also} " $2; next }
+ { print $1 "\t{see} " $2 }
+' $*