diff options
| author | ericj <> | 2002-02-19 23:19:39 +0000 |
|---|---|---|
| committer | ericj <> | 2002-02-19 23:19:39 +0000 |
| commit | 31a22424aa35acd1cf9df9a6c4c3487c347da1c4 (patch) | |
| tree | cabff89a2fb4291caf9ecdacb0746aafacaf299e /src/usr.bin/nc/scripts/alta | |
| parent | a03c0e851f1aaa82f73eef4a7673768cae02b444 (diff) | |
| download | openbsd-31a22424aa35acd1cf9df9a6c4c3487c347da1c4.tar.gz openbsd-31a22424aa35acd1cf9df9a6c4c3487c347da1c4.tar.bz2 openbsd-31a22424aa35acd1cf9df9a6c4c3487c347da1c4.zip | |
remove more old cruft
Diffstat (limited to 'src/usr.bin/nc/scripts/alta')
| -rw-r--r-- | src/usr.bin/nc/scripts/alta | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/src/usr.bin/nc/scripts/alta b/src/usr.bin/nc/scripts/alta deleted file mode 100644 index ed4bd3917c..0000000000 --- a/src/usr.bin/nc/scripts/alta +++ /dev/null | |||
| @@ -1,35 +0,0 @@ | |||
| 1 | #! /bin/sh | ||
| 2 | # $OpenBSD: alta,v 1.2 2001/01/29 01:58:12 niklas Exp $ | ||
| 3 | |||
| 4 | ## special handler for altavista, since they only hand out chunks of 10 at | ||
| 5 | ## a time. Tries to isolate out results without the leading/trailing trash. | ||
| 6 | ## multiword arguments are foo+bar, as usual. | ||
| 7 | ## Second optional arg switches the "what" field, to e.g. "news" | ||
| 8 | |||
| 9 | test "${1}" = "" && echo 'Needs an argument to search for!' && exit 1 | ||
| 10 | WHAT="web" | ||
| 11 | test "${2}" && WHAT="${2}" | ||
| 12 | |||
| 13 | # convert multiple args | ||
| 14 | PLUSARG="`echo $* | sed 's/ /+/g'`" | ||
| 15 | |||
| 16 | # Plug in arg. only doing simple-q for now; pg=aq for advanced-query | ||
| 17 | # embedded quotes define phrases; otherwise it goes wild on multi-words | ||
| 18 | QB="GET /cgi-bin/query?pg=q&what=${WHAT}&fmt=c&q=\"${PLUSARG}\"" | ||
| 19 | |||
| 20 | # ping 'em once, to get the routing warm | ||
| 21 | nc -z -w 8 www.altavista.digital.com 24015 2> /dev/null | ||
| 22 | echo "=== Altavista ===" | ||
| 23 | |||
| 24 | for xx in 0 10 20 30 40 50 60 70 80 90 100 110 120 130 140 150 160 170 180 \ | ||
| 25 | 190 200 210 220 230 240 250 260 270 280 290 300 310 320 330 340 350 ; do | ||
| 26 | echo "${QB}&stq=${xx}" | nc -w 15 www.altavista.digital.com 80 | \ | ||
| 27 | egrep '^<a href="http://' | ||
| 28 | done | ||
| 29 | |||
| 30 | exit 0 | ||
| 31 | |||
| 32 | # old filter stuff | ||
| 33 | sed -e '/Documents .* matching .* query /,/query?.*stq=.* Document/p' \ | ||
| 34 | -e d | ||
| 35 | |||
