[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: funny thing about "docs.info.apple.com"



On Wed, 14 Dec 2005, Gene Linkoski wrote:

Not sure if there is a real easy way to automate downloading all of
them on the Apple II. You may be able to write a Spectrum script to
download them somehow, but I haven't explored Spectrum's scripting
abilities.

I wrote this quick BASH script under Linux. Change 9999 to the last
document you want to download. The documents may have some formatting
errors, but most should be readable. This will create files 9999 text
files, named #.txt in the current directory

i=1
while [ $i -le 9999 ]
do
lynx -center -dump http://docs.info.apple.com/article.html?artnum=$i
$i.txt
sleep 2
let i=i+1
done

This might work too.

#!/bin/bash
for x in `seq 1 9999`
 do
  curl http://docs.info.apple.com/article.html?artnum=$x > $x.txt
  sleep 2
 done

-uso.