AmiCron - Cron task for the Amiga This is a rather crude but effective version of the Unix (tm) program known as "cron" modified to run on an Amiga. For those who aren't Unix knowledgeable, cron is a background task which uses a disk-resident table to automatically run certain tasks on a regular basis. The cron table's format is very simple...it contains entries in the form of lines where each line has 6 fields and each field is separated by "white space" (either tabs or spaces) from it's neighbor. The fields are as follows: 1. Minute (0-59) 2. Hour (0-23) 3. Day (1-31) 4. Month (1-12) 5. Day of week (0-6 where 0=Sunday and 6=Saturday) 6. Command This is the command to be run at the appointed time. It will be run just as if typed into the CLI. Each of the first 5 fields are numbers. However, it is permissable to use an asterisk (*) in a field to mean ALL possible numbers for that field, and you can specify a series of numbers separated by commas (,) and ranges separated by dashes (-). For instance, in the Day field you could specify "1,5,10" to mean the first, fifth, and tenth days of the month; or you could specify "1-15" to mean the first through the fifteenth of the month. Here are some examples of Amicron table entries: Print the date in the crontask window every minute: * * * * * date Print the date in the crontask window on the hour, every hour: 0 * * * * date Run uupc at 4:30 am every day except Sat and Sun: 30 4 * * 1-5 uupc -siscuva Incrementally backup the files every other day at 7:30 pm: 30 19 * * 1,3,5 sdbackup -l -s LAST dh0: incbkup_1: Backup the files on the 1st and 15th of each month at 1:00 am: 00 01 1,15 * * sdbackup -l dh0: SemiBkup_1: The Amicron table file is located using the following path: sys:usr/spool/cron/crontab and errors, if any are logged into the following path: sys:usr/spool/cron/cronerr Crontab entries *MUST* be left justified starting in column 1 and each entry must contain 6 fields, each separated by spaces or tabs. To run Amicron, you must first set up the directory "sys:usr/spool/cron" and then use your favorite editor to create the "crontab" file. Amicron needs a CLI window for displaying the output of the commands it runs...but it can be made as small or large as you wish. Assuming that you have placed Amicron in your command directory (c:), you can start it by typing the following line into a "newcli" window: Amicron Then you can size and move the window anywhere you want, just be sure not to type anything else into the window because that would prevent cron tasks from running. I have an entry in my startup-sequence file that looks like this: run newcli con:0/140/160/50/CronTask s:startcron The "s:startcron" file contains one line: Amicron This automatically sets up a tiny CronTask window and runs Amicron in it. This program was originally written by Steve R. Sampson (UUCP: sys1!killer!sampson), who very kindly responded to my request for a PD cron that I could port to Minix. I haven't done that yet (My new Amiga 2000 came in right after I received the cron program ) but will do so ASAP. The modifications to make it run on the Amiga were very minor! Rick Schaeffer UUCP: seismo!uunet!iscuva!ricks E. 13611 26th Ave. Phone: (509)928-3533 Spokane, WA 99216