home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Crawly Crypt Collection 1
/
crawlyvol1.bin
/
bbs
/
mkill203
/
maxikill.doc
< prev
next >
Wrap
Text File
|
1993-08-31
|
19KB
|
416 lines
*** ** Maxi*KILL 2.03<beta> by Erik Williams
** *** SunFox Productions, Ltd.
*** ** Raleigh, North Carolina
** *** (c) Copyright, 1993. All rights reserved.
LAST REVISED: March 24, 1993
NETWORK ADDRESSES:
AtariNet: 51:102/0 {Triangle Area AtariNet Host}
51:102/1 {SunFox's Realm BBS}
51:102/2 {SunFox's Mail Realm BBS}
FidoNet: 1:151/167 {SunFox's Realm BBS}
1:151/169 {SunFox's Mail Realm BBS}
GEnie: SUNFOX (natch!)
A LITTLE ABOUT Maxi*KILL:
Maxi*KILL was designed over three years ago as a third-party support
programme for Shawn Smith's QWK reader, Maxi*Miser/ST. The original
versions were relatively primitive in that they only took a flat ASCII
text file with a set of descriptor/path pairs and Maxi*KILL would
merrily search those directories for files that matched the pattern and
kill them. I even put in two methods of operation...one that ask you
for confirmation for every file found and one that would just go ahead
and blow away the files without asking you anything. It was crude, but
it killed the QWK and REP files left after I had uploaded my replies to
the QWK packer on the Twilight Zone and I was happy.
A little over a year ago, I had a nasty little partition crash that
just happen to trash all of my source code. Guess what! There went the
source to Maxi*KILL as well. I was fit to be tied as my only good backup
didn't have the sources on there...but Maxi*KILL 1.20 did the job and I
didn't bother updating it any more.
I finally bit the bullet this week and sat down to rewrite Maxi*KILL
and what you have on your system is the results of that. Because my
needs have changed, Maxi*KILL is almost a totally different looking
programme than what I released over three years ago and it is a whole lot
more powerful now than I had ever dreamed back then.
Enjoy it...
WHO WOULD BENEFIT FROM MAXIKILL?
The main audience for this programme will be BBS sysops who want to
fine-tune their control over how they delete files automatically. Because
almost every FidoNet-style BBS is event-driven in one way or another,
Maxi*KILL will allow the user to time the deleting of files to within
*ONE SECOND* (not even BinkleyTerm's events are that good!) of running
Maxi*KILL. Maxi*KILL logs its action in a Binkley-style logging, so you
can have Maxi*KILL merge its output with your regular Binkley logs if you
wish.
However, if you are not a sysop, don't despair! Maxi*KILL can work
for you as well...if you have files that you regularly delete, then this
is the programme for you. All you have to do is set up the configuration
as you want and just run Maxi*KILL whenever you need to delete files. It
is really simple and really powerful.
All in all, anyone who wants to take control of their file deleting
will probably find some use in Maxi*KILL.
BEFORE I GO ANY FURTHER:
As with any programme that plays around with your hard disks, the
author (me!) takes no responsibility for what Maxi*KILL may do to your
hard disk...if your system freaks out, it ain't my fault! I use legal,
documented stuff in Maxi*KILL and the code is so generic that it should
run on *ANYTHING*. It has been tested on a TT030 and a Mega4STE here
at the Realm...and it runs fine. It also runs fine in colour and
monochrome, so that shouldn't be a problem. Essentially, my two
machines are *THE* torture test for new programmes...if it runs on both
of these machines without any problems, it will run on anything.
There are no hidden routines to trash your hard disk or anything
like that, but messed up configurations can really screw up the program.
I'm not trying to frighten you or anything: just configure Maxi*KILL
like I tell you and you will do just fine. Trust me.
Another legal tidbit is that I retain all rights to this programme
and it is a copyrighted piece of software. Just because I distribute it
as postcardware doesn't mean that it is public domain...it isn't. You
are allowed to publish it on your user group disks or distribute it to
any BBS or online service provided you observe the following rules:
-The entire archive must be intact. That includes the programme,
the sample configuration file, and the documentation.
-That if you charge a fee that it only cover the cost of the disk
itself.
-That you do not disassemble or otherwise reverse engineer the
programme. I'm willing to share sources with programmers who
want to see how I do things...like parsing and so forth. It
isn't the greatest code, but it works. All I ask if you use
the code in your programmes that you attribute me as a source
in your documentation! I wouldn't mind seeing your code as
well...but that's not required. :)
HOW MUCH IS THIS WORTH TO YOU?
I'm not going to ask for much! Maxi*KILL comes fully enabled so I
will not expect you to send any money to me (though I'm not above
accepting it if sent!) or pay me with GEnie gifts of time or any such
nonsense.
However, I have a bit of vanity like every other shareware programmer
out there in that I like to see just how far my programme will go in this
world. What I would like is a *POSTCARD* from your hometown...you don't
even have to put your address or anything personal on it. Even if you do,
I'm not going to bug you and try to sell all sorts of garbage to you or
sell your name to every mailing list I can find (I'd hate it if that
happened to me, so I'm not going to do it to you). Mainly, it is just to
satisfy my curiosity more than anything else...I just want to see how far
Maxi*KILL gets distributed.
You can't beat a deal like this! Fourteen or so cents for a program
like this?!? I've got to be out of my mind (which is probably true!).
What you do get if you send a postcard is someone willing to put special
features into the programme...I'll support those people who support me
in this postcardware project. I have a lot of plans for Maxi*KILL and
I'm willing to listen to ideas...and I'm not asking for much in return.
Send your postcards to:
Erik Williams
SunFox Productions, Ltd.
2801-4 Brigadoon Drive
Raleigh, North Carolina 27606-3051
Thank you for your support. Now, on with the documentation!
I'm also available at those net addresses above for bug reports,
gripes, and so on. If you are on AtariNet or FidoNet, direct your
netmail to 51:102/1 or 1:151/167, respectively. The Mail Realm is my
private, mail-only node and is more of an offline reader than anything
else! Thanks!
CONFIGURING THIS BUGGER:
Configuring Maxi*KILL is a breeze as long as you do it *MY WAY*
(you know, "there's the right way and the Army way, but dammit, we're doing
it *MY* way!"). The syntax is simple and I've put a lot of code in to try
to trap out as many possible syntax errors as I can, but even I could have
missed a case or two.
In general, the configuration file is a flat ASCII text file that is
relatively free-form (I say this because it really doesn't matter what
order these entries are in or the spacing, but the syntax must be
observed exactly or unpredictable things may occur). There are no
provisions for comments...that will be a later addition to the programme.
This configuration file *MUST* be named MAXIKILL.CFG and reside in the
folder from which you run Maxi*KILL. This is the only file that
must remain in this directory and have this name...the rest of Maxi*KILL
is user-configurable.
The following is the list of acceptable configuration commands...all
parameters associated with these commands are REQUIRED for Maxi*KILL to
function correctly! You must have LogLevel, LogEvent, and LogMaint
defined at the very least or else the programme will crash when it tries
to write to a closed file. It would also be nice if you had at least one
Event defined as that is the purpose of the programme! ;)
A word of warning: all of these keywords and parameters are case
sensitive with the exception of the <start_time>, <end_time>, <path>, and
<pattern>.
CONFIGURATION FILE COMMANDS:
Event <day> <start_time> <end_time>
Kill <path> <filename_pattern>
EndEvent
The Event...EndEvent pair is extremely powerful and can time your
file deletions to within one second of running Maxi*KILL.
The <day> parameter can be any one or a combination of the following
options:
Mon = Monday
Tue = Tuesday
Wed = Wednesday
Thu = Thursday
Fri = Friday
Sat = Saturday
Sun = Sunday
Week = Monday through Friday
WeekEnd = Saturday and Sunday
All = All seven days
The days are case-sensitive, so please use these abbreviations
exactly as you see them. If you wish to use more than one of these
days in your Event, then join them together using the "|" character
with *NO* spaces in the specification. For example:
Event Mon|Wed|Fri 00:00:00 00:05:00
Kill g:\turbo\ turbo.log
Kill c:\turbo\ turbo.log
EndEvent
This event will only run on Monday, Wednesday, or Friday.
You can pipe together the Week, WeekEnd, and All specifiers as well
but be warned that the first "All" encountered will set the all of
of the days as valid days for the Event to be run and anything that
comes after the "All" will have no effect.
You may also have as many Kills within an event as your memory
allows...I'm using a linked-list structure for the events and kills
which really saves memory over the old array-based format.
Your date specifier is limited to 45 characters...that's why I added
the Week and WeekEnd specifiers to make specifying those multiple days
a bit easier for you.
The <start_time> and <end_time> are twenty-four hour representations
of your starting and ending times respectively. Each of these will
be eight characters long in the following format:
hh:mm:ss
It is essential that you follow this format exactly or my time
comparison routines may have unexpected results. So, for example,
if you want a start time of 4:30p on the dot, just put in 16:30:00
for <start_time>.
A word of warning: you need to keep your times from crossing over
the midnight boundary or else unpredicted results may come of it.
So, avoid an Event like this:
Event All 23:30:00 00:05:00
Kill c:\turbo\ turbo.log
EndEvent
The Kill definitions will be described below in its own section.
When a Kill is located within an Event, it will only be executed
if the time that Maxi*KILL was run is between or equal to the
starting or ending times of the event and the startup day is equal
to the event day (thus, if "Fri" is the day, then the event will
only run on Fridays and "All" means that it will run at the specified
time on *ANY* day and so on). Otherwise, it will be ignored.
Finally, all events must end with the EventEnd keyword. This is my
marker that tells me this event definition is done and that I can
reset the parser to look for new keywords. Also, this block-style
definition is easier for you to read and debug if there are
problems.
Kill <path> <pattern>
The <path> is a simple path specification such as "c:\turbo\". Note
that the trailing backslash is required...if you forget it, then
Maxi*KILL will assume it is looking at a file name one level higher
than where you wish to search which may cause problems.
The <pattern> is the pattern of the file that you wish to delete.
This pattern can include the "*" and "?" wildcard characters or it
may be any legal filename. The "*" replaces any number of characters
when trying to match filenames, the "?" replaces only one character.
LogFile <path\filename>
LogFile tells Maxi*KILL where and what file is to be used as the log
of Maxi*KILL's activities. This is a full path and filename (as
opposed to the path of the Kill directive, so make sure that you
define it as such (i.e., "g:\logs\sunfox.log").
The log is laid out in the BinkleyTerm style that is popular in
most FidoNet BBS software for the Atari and other platforms. Here
is an example from an actual log file:
> 04 Mar 16:38:26 KILL Beginning events processing...
~ 04 Mar 16:38:26 KILL
~ 04 Mar 16:38:26 KILL Checking Event #1...
~ 04 Mar 16:38:26 KILL Startup date/event date mismatch...no execution!
~ 04 Mar 16:38:26 KILL Checking for next event...
~ 04 Mar 16:38:26 KILL
~ 04 Mar 16:38:26 KILL Checking Event #2...
~ 04 Mar 16:38:26 KILL Startup date/event date match...now checking times!
~ 04 Mar 16:38:26 KILL Startup time after end of event...no execution!
~ 04 Mar 16:38:26 KILL Checking for next event...
LogLevel < {1,2,3} >
LogLevel defines how much logging Maxi*KILL will do for you.
LogLevel 1 is just the basic amount of logging that anyone gets...
Maxi*KILL tells you what it is doing and that is about it.
LogLevel 2 will give you everything from LogLevel 1 plus a dump of
your event definitions like this:
+ 31 Aug 22:29:58 KILL Configuration file has the following Event entries:
+ 31 Aug 22:29:58 KILL
+ 31 Aug 22:29:58 KILL Event 1:
+ 31 Aug 22:29:58 KILL
+ 31 Aug 22:29:58 KILL Day(s): Mon|Wed|Fri
+ 31 Aug 22:29:58 KILL Starting Time: 00:30:00
+ 31 Aug 22:29:58 KILL Ending Time: 18:45:00
+ 31 Aug 22:29:58 KILL
+ 31 Aug 22:29:58 KILL Event Kill Path: k:\tempkill\
+ 31 Aug 22:29:58 KILL Event Kill Pattern: *.log
+ 31 Aug 22:29:58 KILL
+ 31 Aug 22:29:58 KILL Event Kill Path: k:\tempkill\
+ 31 Aug 22:29:58 KILL Event Kill Pattern: *.lst
+ 31 Aug 22:29:58 KILL
+ 31 Aug 22:29:58 KILL Event Kill Path: k:\tempkill\
+ 31 Aug 22:29:58 KILL Event Kill Pattern: *.txt
+ 31 Aug 22:29:58 KILL
+ 31 Aug 22:29:58 KILL Event Kill Path: k:\tempkill\
+ 31 Aug 22:29:58 KILL Event Kill Pattern: *.tpl
+ 31 Aug 22:29:58 KILL
+ 31 Aug 22:29:58 KILL EndEvent 1
+ 31 Aug 22:29:58 KILL
+ 31 Aug 22:29:58 KILL Event 2:
+ 31 Aug 22:29:58 KILL
+ 31 Aug 22:29:58 KILL Day(s): Thu
+ 31 Aug 22:29:58 KILL Starting Time: 16:22:00
+ 31 Aug 22:29:58 KILL Ending Time: 23:25:00
+ 31 Aug 22:29:58 KILL
+ 31 Aug 22:29:58 KILL Event Kill Path: g:\misc\
+ 31 Aug 22:29:58 KILL Event Kill Pattern: *.txt
+ 31 Aug 22:29:58 KILL
+ 31 Aug 22:29:58 KILL EndEvent 2
+ 31 Aug 22:29:58 KILL
+ 31 Aug 22:29:58 KILL Event 3:
+ 31 Aug 22:29:58 KILL
+ 31 Aug 22:29:58 KILL Day(s): All
+ 31 Aug 22:29:58 KILL Starting Time: 00:00:00
+ 31 Aug 22:29:58 KILL Ending Time: 23:59:59
+ 31 Aug 22:29:58 KILL
+ 31 Aug 22:29:58 KILL Event Kill Path: g:\logs\
+ 31 Aug 22:29:58 KILL Event Kill Pattern: *.ltr
+ 31 Aug 22:29:58 KILL
+ 31 Aug 22:29:58 KILL EndEvent 3
LogLevel 3 will give you everything from LogLevel 2 plus a dump of
your log file maintenance schedule like this:
+ 10 Mar 16:09:48 KILL Configuration file has the following LogMaint setting:
+ 10 Mar 16:09:48 KILL
+ 10 Mar 16:09:48 KILL Day(s): All
+ 10 Mar 16:09:48 KILL Starting Time: 00:00:00
+ 10 Mar 16:09:48 KILL Ending Time: 23:59:00
I recommend that you start out at LogLevel 3 to make sure you have
everything defined correctly...then you can drop Maxi*KILL down to
LogLevel 1 once everything is working smoothly. LogLevel numbers
other than 1-3 are not supported at this time.
LogMaint <day> <start_time> <end_time>
LogMaint was added to allow easy maintenance of the log file. For
obvious reasons, the log file was the only file that could not be
deleted by Maxi*KILL and an attempt to try deleting it using a Kill
or Event usually ended up crashing the machine!
LogMaint follows the same rules as the Events in terms of the format
of the <day>, <start_time>, and <end_time>. If the day matches the
system date and the system time is between the start and end times
of LogMaint, then the log file will be reinitialised and will start
from scratch. Otherwise, any logging will be appended to the
existing log file. Again, avoid going over the midnight boundary
when setting your LogMaint times.
If you have a logs folder in which all your log files have the same
extender, then you might want to give your Maxi*KILL log a unique
extender so that you may have a Kill definition to delete your other
log files if you so desire.
Here is a sample MAXIKILL.CFG:
Here is the MAXIKILL.CFG that helped to create the log listings as
given above for LogLevel 4. It will also show you how you should
create your own MAXIKILL.CFG.
----8<----------------------------------------------------------snip!
LogLevel 4
LogMaint All 00:00:00 23:59:00
LogFile g:\turbo\text\sunfox.log
Kill g:\turbo\ turbo.log
Event All 00:30:00 18:45:00
Kill k:\tempkill\ *.log
Kill k:\tempkill\ *.lst
Kill k:\tempkill\ *.txt
Kill k:\tempkill\ *.tpl
EndEvent
Event Thu 16:22:00 23:25:00
Kill g:\misc\ *.txt
EndEvent
Event Thu 16:00:00 19:05:00
Kill g:\misc\ *.ls?
EndEvent
----8<----------------------------------------------------------snip!
THHHH...THHHH...THAT'S ALL FOLKS!
That's it...that's all there is to configuring Maxi*KILL. It's so
simple even *I* could do it...and I'm just the programmer! If you like
what you see and use it, please send the postcard. If you find a bug,
let me know and I'll fix it. I'll even take feature requests from
people who send me postcards! Use it, have fun, and enjoy! :)
Erik Williams
SunFox Productions, Ltd.
Raleigh, North Carolina