home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Dream 46
/
Amiga_Dream_46.iso
/
Amiga
/
Internet
/
Irc
/
ChatBox1_164.lha
/
Rexx
/
aminetfind2.cb
< prev
next >
Wrap
Text File
|
1997-10-24
|
847b
|
46 lines
/**/
indexfile='dh2:net/index'
parse arg keywords
if keywords='' then do
CMD '/echo Usage: /find [-opts] keywords'
exit
end
keys=1
length=10
width=80
say=0
do while left(keywords,1)='-'
opt=word(keywords,1)
opt=upper(right(opt,length(opt)-1))
if opt='SAY' then say=1
parse var keywords .' 'keywords
end
if ~showlist(H,'TCP') then address command 'mount TCP: from amitcp:devs/inet-mountlist'
if ~showlist(H,'TCP') then address command 'mount TCP:'
if showlist(H,'TCP') then do
if open(1,'TCP:find.germany.aminet.org/1848',w) then do
call writeln(1,'find 'keywords)
call writeln(1,'quit')
linecnt=0
do until eof(1)
text=readln(1)
linecnt=linecnt+1
if linecnt<=length then do
if text~='' then do
CMD '/echo' text
end
else linecnt=linecnt-1
end
end
CMD '/echo' linecnt' matches found.'
end
end