_____ ______________________________ \\ \\\_____//\__/\\_\\ __ //\____/ ---------/\---------// /\ // /_/ \\ \ // // __// /_/---------/\------------- ---------\/--------// /_/// /_____\\ \// // \// /___---------\/------------- \\/___\\____//___\//_//_/\_\\____/ Nameless - -- ---=*)> PRESENTS: <(*=--- -- - *** AETop v2.2 WB2.0 ONLY! *** AmiExpress Util to list Top Uploader/Downloader/Leeches This program will quickly and easily list your top AmiExpress BBS (bytes) uploaders (UL), downloaders (UL), or leeches (DL-UL - Downloaders who havn't uploaded much) and the number of bytes uploads per download ratio (or vice versa) they're at. Let me say right up front, This program has two limitations (1) It is now WB2.0+ only (2) It'll only work if you have LESS THAN 1250 users in your user.data (like anybody has more than that). Other than that this program is completely safe and should not cause any problems, it ONLY reads the BBS:user.data file and writes ONLY if you specify it to write something (with '>' or '-U' or '-D' options). I should also mention you need to have your user.data file in a BBS: dir (or assign BBS: where it is) SYNTAX (FOR USE FROM SHELL/SCRIPT..) ==================================== The syntax is as follows: AETop (Qty) [-A] [-C] [-U] [-D] [-F(Headerfile)] [REG] where: [((( MANDATORY ARGUMENTS )))] (Qty) is a nr 1-1249 which represents how many users to list [((( OPTIONAL SWITCHES )))] -A Force ANSI COLOR mode (default WITH -D or -U is NO ANSI) Note this will not change the output of your header file! It will xfer ansi in header irregardless of this switch. -C turns on and issues a SCREEN CLEAR at beginning of output -U ..... Selects to display top uploaders -D ..... Selects to display top downloaders (LEECHES!) is the destination filename for TOP UPLOADERS is the destination filename for TOP DOWNLOADERS (leeches) -F(headerfile) Will add a custom text header file at the top of the output. REG Turns on REGular DOWNLOADER sort routine, rather than listing the LEECHES (Top Download bytes - Upload bytes) this will sort users by Top Download bytes only. NOTE: If you dont specify a for your -U or -D options it automagically defaults to standard output (ie.. your shell), furthermore, by doing it this way you CAN have BOTH switches set AND redirect output (with the > and < arrows) to a file [giving you both top ul & leeches in 1 output]. DIFFERENCES BETWEEN -U and -D Options ===================================== Right offhand they look pretty similar, There are 2 distinct differences: (1) -U switch will sort them by the TOP BYTES UPLOADER, while, -D will calculate the top BYTES DOWNLOADED - BYTES UPLOADED and display them based on this (takes good uploaders into account now!) UNLESS you have the 'REG' switch on, then it will ONLY sort based on BYTES DOWNLOADED. (3) -U will list a ratio of users bytes UPloaded PER every byte DownLoaded -D will list the reverse ratio (bytes DOWNloaded per every byte UPloaded) My BBS is strictly set up to report everything by BYTES uploaded or downloaded, as opposed to ratios or qty of files. AND SO IS THIS UTILITY! SAMPLE OUTPUT COMMAND ISSUED: AETop >thisfile 5 -C -U -D -FBBS:LeGaCy.head1 ============= ___ ____________________________ __ T H E 5 / / / ___/ ____/ _ / ___/ // /\ A N D T H E / /__/ __// /_ / _~ / /___\ ~ / / B E S T /\____/\____/\_____/__//__/\____/\/__/ / 5 W O R S T _______________/ \/___/\/___/\/____/\__\\__\/\___\/\__\/ \___________________ TOP UPLOADERS!! FROM BYTES UL BYTES DL UL PER DL ---------------- ----------------------- ------------- ------------- --------- SpaZm Cocoa, FL 43,960,341 20,710,011 2.12/1 RAZOR Merritt Island, Fl, USA 34,608,721 38,591,854 0.90/1 Dalai Lama * AmigaPhile BBS * 25,570,845 933,396 27.40/1 The Overlord Merritt Island, Fl, USA 25,456,511 15,703,090 1.62/1 Otto Cocoa, Fl, USA 25,200,000 75,597,002 0.33/1 LEECHES (DL-UL) FROM BYTES DL BYTES UL DL PER UL ---------------- ----------------------- ------------- ------------- --------- Prince Valinor Orlando, Fl, USA 75,597,002 25,200,000 3.00/1 Badguy1 Merritt Island, Fl, USA 19,483,851 7,036,776 2.77/1 Badguy2 MIMS, FL, USA 16,073,380 8,990,274 1.79/1 Badguy3 Rockledge, Fl, USA 18,233,524 12,199,648 1.49/1 Badguy4 Muncy, Pa 12,372,625 6,697,967 1.85/1 ------------------------------------------------------------------------------ *** AETop v2.2 by Nameless of - DeSiRe - Call our boards! (407)267-8155 *** SCRIPT FILE USE =============== This new version can output to selected filenames (You can even create 2 seperate TOP UL and TOP LEECH files from a single command!). And you can still SAFELY include this in the script (batch) file that AmiExpress runs at the end of each logoff [to keep things current], you just have to change your syntax a little. Don't worry - I threw in LOTS of error checking/handling AETOP shouldn't guru! (Unless you're trying to do it under WB1.3!). To include it in your script file I suggest you test your syntax a few times, from shell, before you hardcode it into your script... an easy test would be: AETop 10 -A -D <- outputs to stdio since no filename is specified or AETop 1249 -U -Ftxt <- will display all your uploaders! with a 'txt' file or AETop 3 -U -D <- will display both top Uploaders & top LEECHES or even AETop 3 -U -D REG <- will display both top UPloaders & top DOWNloaders or even AETop 10 <- this only works for versions 0.1-0.5 and 0.9 & up and of course you can test its capability to output directly to files with... AETop 10 -A -Dram:leeches -Uram:topuser then just issue the AmigaDos Type command, to view the files, as follows: Type ram:leeches and Type ram:topusers BTW this is kind of how I do it in my script file... +-----------------------------------------------------------------------------+ | | |AETop 10 -A -C -Dbbs:conf/bulletins/bull1.txt -Ubbs:conf/bulletins/bull2.txt | | | |AETop >bbs:conf/bull.txt 5 -A -C -U -D -FBBS:Desire.head1 | | | +-----------------------------------------------------------------------------+ This may seem deceptive, but it creates 3 files. The top line creates 2 top10 files in the bulletins area, and the bottom line creates 1 file 'bull.txt' which has top 5 uploaders & 5 leeches and is viewed once as the user enters the conf area. If ya don't understand, call my board and LOOK! AETOP REVISION HISTORY ====================== v0.1 => 09 Mar 92 - INITIAL RELEASE v0.2 => 13 Mar 92 - Removed a redundant variable assignment. - Added some ansi colors to the help. - Fixed top count to include the last user (had a -1) v0.3 => 14 Mar 92 - Added the RATIO column, reduced size of other 2 - Added check to ensure correct user.data format exists. - Modified it to use the Amiga Open() and Close() functions rather than the stdio fopen() and fclose() v0.4 => 01 Apr 92 - Changed the ul to dl ratio calculation to add +1 ONLY TO USERS who have a zero for ul or dl, to prevent div by zero (before this I just added 1byte to denominator for ALL USERS to prevent a div by zero error). v0.5 => 02 Apr 92 - Added UL PER DL as a secondary sort field, in case users have the same bytes uploaded (like the lamers with 0!) - Created AELEECH utility, similar but shows top downloaders v0.6 => 03 Apr 92 - Merged the AETop and AELeech into ONE utility, this was done for speed and to save drive wear by makeing 1 pass to read user.data file to create my 2 output files. - Added ANSI switch, now defaults to NON-ANSI colors mode - Changed output to SPECIFIED filename(s) rather than the standard output (had to since there are two outputs) v0.7 => 04 Apr 92 - It now retains the capability to be run from shell (for a quick view) by selecting the -D and/or -U alone without a filename. Of course it can also be included in a script file to update both topul and topdl immediately upon user logoff. v0.8 => 17 Apr 92 - Corrected the name & from size limit, previous versions allowed 19 chrs for name but didn't clip it to that. long names would screw up display. Damn, a bug! v0.9 => 17 Apr 92 - Made syntax reverse compatible with versions v0.1 - v0.5, I had changed the syntax on v0.6, this version now also runs with the previous syntax: AETOP to display TOP UPLOADERS only.... I did this for quick use from shell or cli, or to redirect >FILE like before. NOTE: default with old version was to use ANSI, so if you want no ansi you must now select the -U or -D or both switches without the -A ANSI ON switch. v1.0 => 17 Apr 92 - Added the ability to CLEANLY show both top uploaders and top leeches in one command, try... AETOP 5 -A -U -D by trimming the header lines, also lets you add another user in the list with less wasted space. - Added new switch, -C (note all switches ARE case sensitive) With it selected it will add a /f (screen clear) at beginning of every output file. - Major code cleanups, reduced size by over 10% v2.0 => 24 May 92 - Practically a total re-write for use with WB2.0 ONLY!!! Managed to add new features & reduce pgm size by over 30%!!! Changed all stdio functions to use the Amiga2.0.lib equivalents, now stdio = Output() and uses WB2.0 dos.library functions like FRead()... - Added the -F option to add a header text File at the top of output(s). - Added commas in the bytes columns to make it easier to read, had to shift size up a little, sacrificing the NAME & FROM fields a little. Also extended overall width by 2 chrs. - Modified it to ignore INACTIVE accounts, before it would include them in the list. - Removed that scientific notation from the ratio, now if the DL/UL bytes per UL/DL gets over 9999 it will just print >9999 and if it gets less than .01 it will print 0.00 - Modified the way LEECHES are calculated, used to be the users with the 'TOP BYTES DOWNLOADED' but now It SUBRACTS the users UPLOADED BYTES from the DOWNLOADED BYTES and sorts based on this new figure. I figured this would be the best way to keep my long life users who have uploaded & downloaded ALOT from being called 'leeches' (Cause they're not, when you consider their uploads!). v2.1 => 13 Jun 92 - Added (REG)ular switch for people who want to display regular DOWNLOADERS (DL) with -D switch rather than LEECHES (DL-UL), Someone griped that 'Leech' may not be appropriate in some places so I added this switch for him to show 'DOWNLOADERS' instead... - Modified all switches to be Uppercase OR Lowercase Ie... -C is now the same as -c ...etc... v2.2 => 30 Jul 92 - Previous versions caused a guru when wide 'headers' (>128chrs) were used, this version fixed that bug, enabling you to use BIG ANSI filled headers [Well, about 512 bytes per line] (Thanx 'Ken & Ryu' for pointin' that out). - Minor touchups, removed ctrl-c handling, added version string, Reduced size by another 415 bytes. File size Should be: 12344 also gave credit to my new group 'DeSiRe' - This is a serious group guyz, CALL OUR BOARDS!!! (See numbers below) RELEASE INFO: ============= Lastly, I am running this under workbench v2.04. This version [V2.0] and UP will ONLY WORK UNDER Workbench v2.x and up!!! If you have any problems, call my board and let me know. Later, Nameless Greetz to my new DeSiRe friends!!: The Almighty, Freddy, The Grifter, and all you others... hehe :-) AlSo DoN't FoRgEt To GiVe A CaLl To ThEsE CoOl DeSiRe BoArDs: AtOmIc FaLlOuT - WoRlD HeAdQuArTeR - +31-73-130138 - ArAgOrN CaMeLoT - HeAdQuArTeR - +32-164-89772 - Perceval & Almighty ChAnNeL-X - HeAdQuArTeR - +31-2290-62244 - TyCoOn DaTa CeNtEr - EuRo Hq - +31-8330-16499 - FuTuRe InFeRnO - DuTcH Hq - +31-419-220104 - OuTlAnDeR PhAnToM - BeLgIaN Hq - +32-917-70719 - ThE GrIfTeR & Bip Snarfs' Pub - US Hq - 407-267-8155 - Nameless