Here is how I did it.
1. Create a text file that is stored where ever you want it in your directory structure. I suggest it is in an area without browser access. Here is mine, which I named, "build-links.sh":
Quote:
# Remove Goodstuff files before rebuild
rm /home/bobsie/web/goodstuff/admin/backup/*
rm /home/bobsie/web/goodstuff/New/*
# Rebuild new Goodstuff Lists pages and log actions
/home/bobsie/web/goodstuff/admin/nph-build.cgi > /home/bobsie/web/goodstuff/admin/build_links.log
The file deletes the current backup file (it will be recreated) and all the "What's New" files (which will also be recreated). Once that is done, it then changes to the links admin directory and executes nph-build.cgi.
2. Create a second file, which I call "mycron.txt" and put it anywhere you want as in 1. above. Mine looks like this:
Quote:
# (Re)Build the Links HTML Files for Bob's Good Stuff Lists,
# Visitor Contributed Links, and the Diabetes Bookstore.
# Occurs every 6 hours at:
# 1 & 7 a.m and p.m., PT; 4 & 10 a.m. and p.m., ET
0 1,7,13,19 * * * /home/bobsie/bin/build_links.sh
instead of "0 1,7,13,19 * * *", since you want to run this every 5 minutes, you would put "0/5 0 * * *" (I think that is the right syntax -- type "man cron" or "man crontab" at a shell prompt to double check). Make sure the path points to the file you created in 1. above.
3. At the shell prompt, type "crontab mycron.txt". That will load the file into the cron table for your user name. You can double check it by typing "crontab -l" (lowercase L, not 1) and it should show the entry that you typed in mycron.txt. If it doesn't, you didn't do something right.
All of this assumes you are on a UNIX/Linux system. If all of this fails, please consult your ISP for the correct way to add an entry to your cron table.
The above files can be created offline and then uploaded, via ftp, in ASCII mode.
I hope this helps.
------------------
Bob Connors
bobsie@orphanage.com www.orphanage.com/goodstuff/ goodstufflists.home.ml.org/ [This message has been edited by Bobsie (edited January 09, 1999).]