home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Professional
/
OS2PRO194.ISO
/
os2
/
com
/
bbs
/
downsrt
/
source
/
downsort.scr
< prev
next >
Wrap
Text File
|
1991-06-16
|
77KB
|
1,746 lines
:userdoc sec='Maximus Download File Sort and List Utility (OS/2 and DOS)'
.*
.* For printing: use Bookmaster profile.
.*
.* This file also compilable by IPFC (just ignore the errors!).
.*
:prolog.
.*
.* ==========================================================
.* TRANSLATE tables for host uploads from OS/2 3270-sessions
.* ==========================================================
.dm on3270 on
.if &$SYS ne pc .ti 31 10 78 13 be 30 80 31 15 21 64 23
.if &$SYS ne pc .ti 76 12 77 22 30 32 24 33 6a 11
.if &$SYS ne pc .ti ff 10 17 13 23 30 28 31 9d 21 22 23
.if &$SYS ne pc .ti 8e 12 06 22 72 32 29 33 70 11
.if &$SYS ne pc .ti ba b0 bb 6a
.dm off
.*
.* ╔═╦════╗ ┌─┬────┐
.* ╠═╬════╣ ├─┼────┤
.* ║ ║ ║ │ │ │
.* ╚═╩════╝ └─┴────┘
.*
.dm off3270 on
.if &$SYS ne pc .ti 31 31 78 78 be be 80 80 15 15 64 64
.if &$SYS ne pc .ti 76 76 77 77 30 30 24 24 6a 6a
.if &$SYS ne pc .ti ff ff 17 17 23 23 28 28 9d 9d 22 22
.if &$SYS ne pc .ti 8e 8e 06 06 72 72 29 29 70 70
.if &$SYS ne pc .ti ba ba bb bb
.dm off
.aa on3270 on3270
.aa off3270 off3270
.* ==========================================================
.*
.nameit symbol=VERSION text='5'.
.nameit symbol=SUBVERS text='1'.
.nameit symbol=SUFFIX text=' '.
.*
.*
:title.DOWNSORT
Maximus CBCS DOWNload file SORT and List Utility (OS/2 and DOS)
Version &VERSION..&SUBVERS.&SUFFIX.
:etitle.
:author.Rob Hamerling
:date.
:address.
Vianen, The Netherlands
Phone: ++31-3473-72136 (voice)
FIDO-net: 2&colon.512/4.1098
:eaddress.
:docprof rhrfrule=none
language=english figlist=nopage tlist=nopage ftsep=no
layout=2 fbc=no toc='*3' ldrdots=yes.
:revision id=rev51 run=yes.
:eprolog.
:frontm.
:tipage.
:toc.
:body.
.* ==============================================================
:h1.About DOWNSORT
:p.DOWNSORT was started a few years ago as a program for my own use when
I was SYSOP of the Bulletin Board PC-Square, to get overviews of my
download material for the users.
The program name is related to the SORTing of the collection of
DOWNloadable files, in DOWNward time-stamp sequence and a Bulletin
was the only list that was produced at that time.
Also PC-Square was running BinkleyTerm and OPUS under DOS, and
file-requesting was not so popular then.
:p.Now PC-Square runs with OS/2, BinkleyTerm and MAXIMUS CBCS,
and I'm not the SYSOP anymore but still strongly involved.
As a contribution to PC-Square and the large international Bulletin
Board community of MAXIMUS CBCS boards,
I decided to upgrade my DOWNSORT program to the current software.
But at the same time a lot of improvements and extensions have been
made: many user-configurable options for many more output formats
then the original DOWNSORT.
:rev refid=rev51.
:p.The only dependency of DOWNSORT on MAXIMUS CBCS is a parameter-file
AREA.DAT, which is usually created with a MAXIMUS utility (SILT(P)),
which itself can be used without actually running MAXIMUS!
This is the way I work for testing DOWNSORT.
:erev refid=rev51.
:p.:hdref refid=ahis. gives an impression of the history.
:p.DOWNSORT is now developed in an OS/2 environment, but it is
distributed as 'family'-application: it runs under OS/2 and DOS.
.* --------------
:h2.Registration and Shareware Fee
:p.DOWNSORT is a $ 0.00 Shareware Program.
This means (to me) that you respect the commonly known rules for
shareware, but you don't have to pay me anything.
:p.Registration is voluntary: please send me a netmail message with your
name and (net-)address if you are a regular user of DOWNSORT as SYSOP.
That gives me an impression of the usage and the impact of changes to
DOWNSORT.
:p.If you tell me that you are running DOWNSORT on your Bulletin Board
as service to your users, I'll add your name to the reference list in
:hdref refid=ause. (if you like).
.* --------------
:h2.Warranty
:p.For this price?
You must be kidding!
But I'll listen to your complaints and suggestions, and if time
permits, I'll work on the improvements you suggest.
.* --------------
:h2.Acknowledgements
:p.I would like to thank all users that contributed with constructive
remarks and encouraging appraisals.
Without doubt Emmanuel Sandorfi of 2&colon.320/5 holds the record in
number of suggestions and amount of additionally required programming
effort.
He also provided some additional title-fonts (2 and 3).
:p.I also would like to thank the regular users (SYSOP's of Bulletin
Boards) who made DOWNSORT much more popular than I ever dreamed of!
A collection of geographically dispersed Boards can be found in
:hdref refid=ause..
.* =============================================
:h1.What DOWNSORT can do for you
:p.DOWNSORT is a utility to make overviews of available download files
for Bulletin Board Systems (usually running MAXIMUS CBCS).
The overviews differ in sort sequence, purpose of use and size.
:p.A report is produced for files that could not be listed for any
reason.
.* ------------------------
:h2.Purpose and Objectives
:p.DOWNSORT is designed for the following purposes:
:ol.
:li.Produce different overviews of files which are available for
download by users of the Bulletin Board and by File Requestors.
QUICK and EASY retrieval is the main goal for the lists.
Therefore many lists-types and within a type several variations
should be available: versatility for SYSOP and users.
:li.Report files which are not listed in FILES.BBS, or which privilege
(individual or its area) prevents it from being reported.
This might be caused by several circumstances:
:ul compact.
:li.a file belongs to a collection (area) with a higher privilege than
the selected report privilege (typically the upload area, but also
restricted collections for selected users).
:li.a file appears in FILES.BBS after a &caret.Px-sequence that
specifies a :hp2.higher:ehp2. privilege than the selected report
privilege (newly uploaded files in a combined up- and download
directory).
:li.an typing-error has been made in the filename.ext in FILES.BBS or a
file has been renamed without updating FILES.BBS.
:li.a file is not listed in FILES.BBS on purpose by SYSOP, to prevent
it being downloaded other than by CO-SYSOP.
:eul.
:li.Must be able to run unattended (typically overnight).
:li.Should not disclose files to users (file-requesters) without
positive agreement by SYSOP.
:eol.
.* --------------------
:h2 id=funcs.Functional Description
:p.The program DOWNSORT may create several types of outputfiles.
.*
:h3.File-dates and HPFS
:p.One of the function of DOWNSORT is sorting on file date.
Since the introduction of HPFS in OS/2 version 1.2, there is not one
single file-date anymore!
A file on an HPFS volume has different values for:
:ul compact.
:li.Creation date
:li.LastAccess date
:li.LastWrite date
:eul.
:p.The date you see normally in DIR-listings is the LastWrite date.
Most SYSOPs will have noticed that ZMODEM uploads and file-attaches
give file-dates corresponding to the (LastWrite-) date of the sending
system.
And most utilities handle only this 'single' date.
That means that 'old' (ZMODEM-) uploaded files are generally not on top
of the acquisition lists.
:p.But HPFS stores the date of arrival on your system (Creation) as
well.
DOWNSORT handles this Creation date since version 4.7, although the
lists (see below) contain the 'old fashioned' LastWrite date.
This has the following consequences:
:ul compact.
:li.A new acquisition is on top of lists (if that list is sorted on
date), and are marked in the lists as new
(flag for an 'age' of a week or a month).
:li.The listed file-date is the 'ordinary' date.
So users can judge for themselves if the file is 'new' for them as well.
:eul.
:note.The LastAccess date is not very relevant for the purposes of
DOWNSORT, although SYSOP may see when it was last downloaded.
.* ----------------------------------------
:h2.File reports (list types)
:p.DOWNSORT can produce several types of output reports,
mostly indicated by type of list.
Below follows for each type of list e general description.
.* ----
:h3.ORPHAN report
:p.This is a list of all files in download directories for which
there is no entry in the corresponding FILES.BBS file.
The report contains date, area-name and area-path of the orphan.
The entries are sorted on area and filename.
Not reported are MAXIMUS system files like:
FILES.?BS, *.BAK, DIR.?BS and SYSTEM*.?BS.
:note.If there is an entry for a file in FILES.BBS without a
description, the file is NOT considered to be an Orphan!
.*
:h3.BBS-list
:p.This is a list of downloadfiles that came recently available
(DOWNSORT.BBS).
The list may be sorted on date (newest first) or on filename.
It contains compiled MECCA control sequences, for direct use in
MAXIMUS bulletins: a user-privilege sensitive list!
It might be a good idea to put a translated &lbrk.onexit&rbrk. string,
which translates to &lbrk.&caret.OFpath&rbrk. (without the brackets!).
When a user exits from the BBS-list bulletin, it will fall back to the
exit-bulletin.
:p.The length of the file (number of file-entries) may be limited by
parameters:
:ul compact.
:li.file-count
:li.maximum privilege
:eul.
:p.(never more than available within the privilege limit).
If neither specified it will contain all available files in all download
directories.
:p.To make it a complete MAXIMUS bulletin-file a user-provided header is
included preceding the list and a trailer at the end of the list.
Header and trailer can be built by SYSOP, and may contain any
information and bulletin-control sequences (a sample is provided).
.*
:h3.NEW-list
:p.Basically the same list as above, but in simple ASCII format
and without inclusion of header and trailer files.
:p.This list is suitable for file-requestors as brief overview of the
latest additions, updates or replacements.
.*
:h3.ALL-list
:p.A list of all downloadfiles by area in alphabetical sequence (per
area) on filename.
Files of the same area are listed in groups, separated by imbedded
headers with area-name, -description, and -privilege.
Actual status information is provided in the area-header as well:
area-filecount and -bytecount, and latest acquisition (date and
file-name).
:p.At the end a SUMMARY report shows per area the area-title,
file-count and byte-count, and totals.
:p.This list may be limited by the privilege parameter, but is not
affected by the specification of filecount-limit.
The numbers in area-header and summary report show only what is
available for the particular privilege.
.*
:h3.IPF-list
:p.Same contents, but different format of ALL-list, only useful for
OS/2 users (OS/2 version 1.2+ under Presentation Manager).
This file has the format of an input-file for the Information
Presentation Facility Compiler (IPFC).
.*
:h3.GBL-list
:p.Similar to ALL-list,
but where ALL-list gives the files in groups per area, the GBL-list
ignores area-boundaries and gives a single group, sorted on filename.
For each file the area is mentioned.
There is no area-summary.
:p.SYSOP may choose which of both is suitable to make available to
users, and which to use for himself (or even both).
The GBL-list is especially useful to check on duplicates over area's.
The GBL-list is not limited by the filecount parameter.
.*
:h3.FILES.BBS
:p.A new "FILES.BBS" type of file may be (re-)created for every area.
The contents of the file-information will be about the same as
the original FILES.BBS, but with the following notes:
:ul compact.
:li.A header is generated with area-name, -title, and -privilege.
Also the total amount of files and bytes and the most recently acquired
new file in this area is part of the header information.
:li.The entries are sorted on filename for all files with a privilege
up to and including the area-privilege.
:li.Files can have a privilege other than the area-privilege when the
original FILES.BBS file does contain &caret.Pp-sequences ('p' being a
privilege letter).
This construction will be rebuilt by DOWNSORT.
Files with a higher privilege than the area-privilege will follow
after a compiled MECCA-sequence (&caret.Pp) in the new FILES.BBS.
DOWNSORT respects these indicators when reading FILES.BBS,
so all file-privilege information is retained.
This ensures no accidental loss of file-information, and the regular
user won't see more than he should.
:li.Wild-card specifications are not propagated to the new FILES.BBS.
:li.The file description is kept internally as a single string of
maximum 240 characters.
When creating FILES.BBS files, this will be the file format (single
record per file-entry).
The original FILES.BBS may contain a (long) single string
description, or multiple (short) multiline descriptions.
When encountering multiline descriptions in input-FILES.BBS, DOWNSORT
concatenates the separate description lines with a single intermediate
space up to a maximum of 240 bytes.
This will be the output format if the FIL-list is requested.
:rev refid=rev51.
:li.All comments and alignments you may have worked on for many hours
is discarded!
:erev refid=rev51.
:eul.
:p.See for naming conventions and placements :hdref refid=hcmd..
.* -----------------------------
:h2.General notes about the lists
:ol.
:li.Dates are marked with a 'new'-indicator: a '*' if the file
is only since a week on this system, and a '+' if it is since a month.
Filedates later than the current system date are marked '-' (negative
age).
:li.In every outputfile the filename, MAXIMUS-area name, file-size and
-date, and file-description from FILES.BBS is listed.
A report-line will never display more than 79 characters.
:p.The file-description will be multi-line in ALL-, IPF- and GBL-list
if it is longer than would fit on the standard 79-position line, a
word-wrapping technique is used for readability (line-split on word
boundary).
The description is truncated at end of line in BBS-list and NEW-list.
:p.The -T option will force truncation of the description in all reports,
the -W option will allow multi-line descriptions in all reports.
:p.If a filename is found in FILES.BBS, but no accompanying description,
a "--- no description available ---" will be put in place.
A replacing text may be specified with DOWNSORT.CFG.
:p.Files for which there is no entry in the FILES.BBS (Orphans) are
treated as Hidden files, which are only listed in the reports if the
Hidden privilege is specified.
For a way to override this see: :hdref refid=orphan..
:rev refid=rev51.
:note.If you want the orphans to appear in FILES.BBS (or in any other
report), you MUST also request an ORP-list!
:erev refid=rev51.
:li.The BBS-list contains MAXIMUS authorisation controls
(&caret.PLp-sequences), corresponding to the privilege of the area or the
individual file.
So it is not necessary to make different files for different categories
of MAXIMUS users, even with the default privilege-limit SYSOP a
user will not see the files he/she is not supposed to know about.
:p.NEW- and ALL-lists do not contain any privilege information,
the files (or complete area's) above the specified privilege are simply
not listed, however multiple lists can be produced for different
categories of users (based on privilege).
:eol.
.* ==============================================
:h1.How to use DOWNSORT
:p.This chapter tells you how to install DOWNSORT,
how to customise the configuration file and what you might specify on
the commandline.
:p.A sample configuration file (in :hdref refid=acfg.) is part of the
package.
It contains a lot of comments (in Binkley and MAXIMUS style)
to help you with the changes.
.* --------------------------
:h2 id=inst.Installation
:p.With the following directions you should be able to setup and run
DOWNSORT after very short time.
:ol.
:li.Make a separate directory for DOWNSORT, and make it the current
default directory every time you run DOWNSORT.
The separate directory is a recommendation, not a requirement!
:li.Copy the files DOWNSORT.EXE and DOWNSORT.CFG
from the DOWNSORT package into this directory.
:li.Modify (edit) the file DOWNSORT.CFG to specify your environment and
list requirements.
The sample file contains comments to help you with this process.
Most specifications are obvious.
AreaDat is the most important parameter:
DOWNSORT won't do anything useful if it cannot find this MAXIMUS
file.
See :hdref refid=acfg. for a printed sample.
:li.You may give DOWNSORT a first shot by just using its name
on the commandline, with the parameter -H.
This will show a brief HELP-screen with the possible commandline
parameter specifications.
:li.All reports will be created in the DOWNSORT directory
(unless you specified 'fpath' for the FILES.BBS output).
Browse the lists to see if you like the contents and titles, and modify
the CFG-file to your convenience.
:eol.
.* --------------------------
:h2 id=hcmd.Commandline parameters
:p.This paragraph deals only with the commandline parameters!
:p.NOTE: Parameters from DOWNSORT.CFG are processed first, commandline
parameters may complete and (partly) override those in the configuration
file.
:p.For how to read the command syntax diagram see OS/2 reference manual.
:xmp.
:cgraphic scale='1.1'.
:on3270.
┌────────────────────────┐
v │
──┬─────────┬─┬────────┬─ DOWNSORT ────┬────────────────────┬─┴─────┤
└─ drive ─┘ └─ path ─┘ ├─ @filespec ────────┤
├─ BBS ─┬──────┬─────┤
│ └─ &colon.p ─┘ │
├─ NEW ─┬───────┬────┤
│ └─ &colon.pp ─┘ │
├─ ALL ─┬───────┬────┤
│ └─ &colon.pp ─┘ │
├─ IPF ─┬───────┬────┤
│ └─ &colon.pp ─┘ │
├─ GBL ─┬───────┬────┤
│ └─ &colon.pp ─┘ │
├─ ORP ──────────────┤
├─ FIL ─┬──────────┬─┤
│ └─ &colon.fpath ─┘ │
├─ nnn ──────────────┤
├──┬─ /T ─┬──────────┤
│ └─ /W ─┘ │
├──┬─ /A ─┬──────────┤
│ ├─ /D ─┤ │
│ └─ /K ─┘ │
├──┬─ /H ─┬──────────┤
│ ├─ /Q ─┤ │
│ └─ /V ─┘ │
└──── /X ────────────┘
:off3270.
:ecgraphic.
:exmp.
.*
:parml tsize=12 termhi=9.
:pt.@filespec
:pd.The character '@' followed by a complete
:hp2.file specification:ehp2. of the
:hp2.DOWNSORT configuration file:ehp2.
(see :hdref refid=hcfg. for details).
This file will be used to specify processing parameters.
If the file cannot be read, only the commandline parameters are used.
:p.NOTE: The use of a configuration file is mandatory when the file
AREA.DAT is not in the default directory when running DOWNSORT.
:p.Default: DOWNSORT.CFG in current default directory.
.*
:pt.BBS
:pd.Create the BBS-list: DOWNSORT.BBS.
:p.Default: DOWNSORT.BBS will not be created.
.*
:pt.NEW
:pd.Create NEW-list(s): DOWNSORT.N&tilde.p,
where 'p' is the appropriate privilege class (see below).
:p.Default: DOWNSORT.N&tilde.p will not be created.
.*
:pt.ALL
:pd.Create ALL-list(s): DOWNSORT.A&tilde.p,
where 'p' is the appropriate privilege class (see below).
:p.nnn-limit does not apply to ALL-list.
:p.Default: DOWNSORT.A&tilde.p will not be created.
.*
:pt.IPF
:pd.Create IPF-list(s): DOWNSORT.I&tilde.p,
where 'p' is the appropriate privilege class (see below).
:p.nnn-limit does not apply to IPF-list.
:p.Default: DOWNSORT.I&tilde.p will not be created.
.*
:pt.GBL
:pd.Create GBL-list(s): DOWNSORT.G&tilde.p,
where 'p' is the appropriate privilege class (see below).
:p.nnn-limit does not apply to GBL-list.
:p.Default: DOWNSORT.G&tilde.p will not be created.
.*
:pt.ORP
:pd.Create ORP-list: DOWNSORT.ORP (orphan report, if any orphans).
:rev refid=rev51.
:p.If an orphan report is not requested, no other report will contain
any orphan information, even when 'Hidden' is specified as reporting
level.
:erev refid=rev51.
:p.Default: DOWNSORT.ORP will not be created.
.*
:pt.FIL
:pd.Create FILES.BBS type of files for each area.
:p.The specification does not apply to FILES.BBS, a privilege-limit
cannot be specified and defaults to SYSOP.
Another privilege limit can be specified however by means of the
configuration file.
:p.For each individual area the following convention will be used
for the name and place of the FILES.BBS list (in this sequence):
:ol compact.
:li.If the "FIL&colon." parameter specifies a directory-path, then for
each area the :hp2.output:ehp2. file "FILES.ac" is put in the specified
directory ('ac' is 1 or 2 char area-code).
Previous files with the same name will be discarded.
:li.If "ListFile" is specified in AREA.CTL, then that name and path will
be used.
:li.Otherwise the file FILES.BBS: will be put in the directory with the
download files.
:eol.
:p.For situations 2 and 3 existing files will be renamed to .BAK
(older .BAK files will be discarded).
:p.Default: FILES.BBS-type of files will not be generated.
.*
:pt.fpath
:pd.Optional directory path specification for FILES.BBS-output.
See the "FIL&colon." parameter for usage.
:p.Default: none
.*
:pt.nnn
:pd.Maximum number of files to be reported in the BBS- and NEW-list(s).
A maximum value of 32767 can be specified,
it does not apply to ALL-, IPF- and GBL-list.
:p.Default: all files up to and including the (specified or default)
privilege class will be listed for all types of lists.
.*
:pt.p
:pd.Single privilege character.
:p.Lists only download files with a privilege of up to and including
privilege 'p'.
The indicator must be the first character of an existing MAXIMUS
privilege level (T, D, L, N, W, P, F, E, C, A, S, H).
No error-message is given for an invalid privilege character,
there will simply be no file-list for an invalid character!
:p.For the BBS-list only a single privilege character is allowed,
the listfile is always called: DOWNSORT.BBS.
:p.Default: S (SYSOP): files of all privilege levels will be listed,
except HIDDEN files (with real Hidden privilege or files for which no
entry could be found in FILES.BBS).
.*
:pt.pp
:pd.Multiple privilege characters (minumum 0, maximum 10).
:p.Make for every valid specified privilege level a download-list
with files of a privilege of up to and including privilege 'p'.
The indicator must be the first character of an existing MAXIMUS
privilege level.
No error-message is given for an invalid privilege character,
there will simply be no file-list for an invalid character!
:p.Applies to ALL-, IPF- and NEW-lists, these are called
DOWNSORT.A&tilde.p and DOWNSORT.N&tilde.p respectively, were 'p'
represents the applicable privilege character.
:p.Default: S (SYSOP): files of all privilege levels will be listed,
except HIDDEN files (with real Hidden privilege or files for which no
entry could be found in FILES.BBS).
.*
:pt./T /W
:pd.Action to be taken if the file description would cause the
reportline to exceed 79 characters:
:ul compact.
:li.T&rbl.-&rbl.:hp4.t:ehp4.runcate the description
:li.W&rbl.-&rbl.:hp4.w:ehp4.rap the description and provide as many
reportlines as needed to show the complete description.
:eul.
:p.Default: -T for NEW-list and BBS-list, -W for ALL-, IPF- and GBL-list.
.*
:pt./A /D /K
:pd.Sort method for BBS-list and NEW-list.
:ul compact.
:li.A&rbl.-&rbl.Sort the files :hp4.a:ehp4.lphabetically on filename.
:li.D&rbl.-&rbl.Sort the files on reversed :hp4.d:ehp4.ate sequence
(newest file on top of list).
:li.K&rbl.-&rbl.:hp4.k:ehp4.eep lines in sequence of FILES.BBS.
:eul.
:p.When the -A option is selected, an additional header-line will appear
in the BBS-list and NEW-list, indicating the latest acquisition.
This line is not needed when these lists are sorted on date, since the
the latest acquisition will be on top of the list!
:p.The -K option is only useful in situations where the files are
primarily grouped on AREA, i.c. ALL-, IPF- and FIL-list.
:p.Default: -D
.*
:pt./H /Q /V
:pd.Operating mode
:ul compact.
:li.H&rbl.-&rbl.:hp4.h:ehp4.elp: display screen with essential
information about running DOWNSORT, such as the command syntax.
In that case the program will not undertake any other action.
:li.Q&rbl.-&rbl.:hp4.q:ehp4.uiet: display only start and
finish-message, and error messages which prevent the program from
proceeding normally.
:li.V&rbl.-&rbl.:hp4.v:ehp4.erbose: display a lot of progress messages.
:eul.
If neither -Q nor -V is specified, than the number of console messages
will be 'intermediate': more than -Q, but less than -V.
:p.Default: none
.*
:pt./X
:pd.Exclude Privilege Indications
:ul compact.
:li.X&rbl.-&rbl.e:hp4.x:ehp4.clude privilege indications in all list-types.
Some SYSOPs want to hide any kind of privilege-system for users and
file-requesters of their Bulletin Board System.
With the -X option specified all privilege indications will be
suppressed.
:note.This does not apply to the compiled MECCA privilege controls in
the BBS-list!
:eul.
:p.Default: none (privilege indications will be reported).
.*
:eparml.
:ol.
:li.All commandline parameters are optional, may be specified in any
sequence and are case independent.
:li.Parameters from the configuration file are processed before those
from the commandline.
This has some side-effects, like:
:ul compact.
:li.If you specify a specific list in DOWNSORT.CFG, it will be created
anyhow, whatever you specify on the commandline.
:li.However, if you specify privilege values on the commandline, only
the commandline values will be used, and none from the configuration
file.
:li.Commandline parameters have a global meaning, and are applied to all
lists (if applicable).
For example: if you specify '-A' on the commandline, all lists will be
sorted alphabetically on filename.
:eul.
:li.Parameters that can be specified with the configuration file only,
and cannot be overridden with a commandline parameter are:
:ul compact.
:li.BLOCK title text, font and BLOCK title suppression
:li.Subtitle lines
:li.Filename and individual list-options
:li.Privilege for FILES.BBS output
:eul.
:li.Even when specified on the commandline, or in DOWNSORT.CFG,
the Orphan-report will be generated only if there are any orphans,
and then the specified parameters apply.
:li.The IPF-list has to be processed by the Information Presentation
Facility Compiler (IPFC).
This compiler is part of the IBM Programmers Development Toolkit version
1.2 and 1.3 (maybe also in some other toolkit).
The following command has to be issued:
:xmp.
IPFC DOWNSORT.IPF /INF
:exmp.
:p.The option "/INF" is essential (but not documented!) to obtain
a viewable file.
Be also sure to have the file DOWNSORT.BMP in your current default
directory, or in DPATH, as this will be imbedded by the IPF-compiler.
The result of the compilation is a file DOWNSORT.INF, which can be
VIEWed with the following command:
:xmp.
VIEW DOWNSORT
:exmp.
:note.
:ul compact.
:li.The names "DOWNSORT", "IPF" and "INF" are used here as sample,
actually the filename depends on the specification in the DOWNSORT
configuration file, the extensions are the IPFC defaults.
:rev refid=rev51.
:li.If VIEW gives 'garbled' columns and hardly readable block-titles,
then it is most likely that you did not install (or removed) the
standard fonts that are delivered with OS/2.
Start the 'control panel utility', select 'installation', 'add fonts'.
Specify in the 'from'-field C:\OS2\DLL (see HELP of control panel).
Now choose at least 1 non-proportional font.
:erev refid=rev51.
:eul.
:eol.
.* --------------------------
:h2 id=hcfg.Configuration file
:p.Almost all processing options may be specified in an optional
configuration file, which can be specified with a commandline parameter.
The configuration file is a somewhat more convenient way to
specify processing parameters, and allows even more customisation.
It is a good place for the more static parameters of your environment,
commandline parameters are nice to create quickly 'another' list
or a different format (for example wrapped or truncated descriptions).
The parameters are only mentioned here for completeness,
see :hdref refid=acfg. for a documented specification sample
of a configuration file.
.* -----------
:h3.Parameters with global scope
:p.The parameters below influence the execution of DOWNSORT,
or have impact on every list (if it is applicable for that list).
:ul compact.
:li.File Specification of the MAXIMUS CBCS file 'AREA.DAT'.
:li.List title with BLOCK-characters.
:li.Font for the BLOCK title.
:li.Pre-titles, Sub-titles and Bottom-lines in 'text' format
:li.Descriptive text of orphans and files without a description
in the input FILES.BBS files.
:li.Maximum number of entries in NEW-list and BBS-list.
:eul.
.* -----------
:h3.Parameters with local scope
:p.The parameters below are sub-parameters of the xxxFileList keyword.
:ul compact.
:li.Up to 10 privileges for NEW-, GBL-, ALL- and IPF-list (each
resulting in a separate list).
:li.Alternate output filename (in stead of the default DOWNSORT).
:li.Directory for the :hp2.output:ehp2. FILES.BBS-lists
:li.Maximum number of file entries in NEW-list and BBS-list
:li.File-entry sort sequence (filename or date).
:li.Wrap or Truncate long file descriptions.
:li.Title Font selection.
:li.Suppression of privilege indications in NEW-, ALL-, IPF- and
GBL-lists.
:rev refid=rev51.
:li.Include textfile in NEW-, ALL-, IPF- and GBL-lists, and in FILES.bbs.
:erev refid=rev51.
:eul.
:p.A sample configuration file (DOWNSORT.CFG) is provided.
A listing of this file is imbedded as :hdref refid=acfg..
It contains a complete specification with comments on:
:ul compact.
:li.which options are available
:li.how to specify the options
:eul.
:p.Read and modify the file as you like.
Copy the sample file to a save place before you start modifying the
original DOWNSORT.CFG!
:p.NOTE: The parameters from DOWNSORT.CFG are processed first, then
commandline parameters, which may complete and will (partly) override
those in the configuration file.
.* -------------------------
:h2.Usability hints
.*
:h3.Specification of AREA.DAT
:p.A MAXIMUS file 'AREA.DAT' is absolutely required by DOWNSORT.
:rev refid=rev51.
It is however not necessary to run MAXIMUS itself,
the AREA.DAT file is created with SILT(P) from the MAXIMUS package.
You can use this utility without the other MAXIMUS stuff.
In fact I do that myself (NOT running a MAXIMUS board)!
:erev refid=rev51.
If you run DOWNSORT in directory without AREA.DAT, then you
have several options:
:ul compact.
:li.You might add a COPY statement in your batch-file to copy AREA.DAT
with every run into your DOWNSORT directory.
:li.You might use the "@path" parameter to specify
the complete filespec of AREA.DAT ("drive&colon.\directory\file.ext").
:li.You may use DOWNSORT.CFG for the filespec of AREA.DAT.
:eul.
:p.The latter is recommended.
:p.Currently DOWNSORT does not allow to select the contents of the lists
on area-code.
The :hp2.'@path':ehp2. allows you to specify a different AREA.DAT file
than the one that is used by your MAXIMUS.
With SILT you may build a special AREA.DAT for exclusive use by
DOWNSORT, with different, less, or more directories!
:p.If DOWNSORT reports a memory constraint
(see also :hdref refid=perf.),
you may use this technique as circumvention: leave out one or more of
the file area's and rerun DOWNSORT with the alternate AREA.DAT
specification.
.*
:h3.Location of FILES.BBS
:p.For input DOWNSORT uses either the ListFile specification in
AREA.DAT, or the download directory to locate the file with
file-descriptions (generally known as FILES.BBS).
:p.The destination of FILES.BBS-files is not by definition the same as
the origin!
When specified with the "FIL&colon."-parameter (or in the configuration
file), the output may be located in a different directory than the
original input FILES.BBS.
Manual checking or post-processing by some other program may follow
DOWNSORT, after which the files might be put back on the MAXIMUS
specified position.
.*
:h3.Privilege control
:p.The default file privilege to be shown is SYSOP.
:p.Files without a matching filename-entry in FILES.BBS are treated as
Hidden.
That means that by default these files will not be listed,
unless the 'H' privilege is used on the report-request specification.
All files with a higher privilege than the specified (or defaulted)
report-privilege will not appear in the report.
.*
.*
:h3 id=orphan.Orphan report
:p.The Orphan report will be generated only if there are any orphans
detected.
In that case it overwrites a possibly present old DOWNSORT.ORP file.
:p.A way of suppressing Orphan-reporting is to include a "*.*"
entry :hp2.at the end:ehp2. of FILES.BBS.
This has two effects:
:ul compact.
:li.In the sense of DOWNSORT orphans do not exist anymore:
there is a matching entry in FILES.BBS for every file.
:li.The description of this entry will replace the hard-code text
"----no-description-----".
You may specify your own text in DOWNSORT.CFG.
:eul.
.*
:h3.Duplicates
:p.No test on duplicates is done, this means:
:ul compact.
:li.If a downloadpath is encountered more than once, the files will
appear that many times in the outputlist (depending on the
area-privilege!)
:li.If a filename.ext is encountered more than once in different
subdirectories, it will appear that many times in the outputlist.
The file-privilege reflects that of the area where the file belongs to
(unless overridden by a &caret.Px modifier in FILES.BBS).
:eul.
.*
.*
:rev refid=rev51.
:h3.Headers, Titles and Include files
:p.There are several ways to custimise the appearance of the lists for
DOWNSORT.
All items in the following list are optional, but the sequence in the
reports is fixed and as listed:
:dl tsize=12 termhi=2.
:dt.Pre-Title
:dd.Up to 20 lines as very first lines of your lists
(sometimes called Top-title).
Any text may be specified.
Leading '~'-characters (tilde) will be treated as full-size required
blanks, mainly to manually align (center) the text in these lines.
There is no automatic centering.
You may have to experiment a little.
:dt.TITLE
:dd.A short title (8-12 characters), that will appear as 'magnified' big
BLOCK-letters.
There are 4 block-fonts to choose from.
Not all characters are supported and lower-case will be translated to
upper-case.
The '~'-character (tilde) will be treated as full-size required blank,
the '`'-character (accent-grave) as half-size required blank.
:p.If not specified, a default title is generated as DOWNSORTxy, where
xy stands for the current version of DOWNSORT.
However even this title may be suppressed by specifying TitleFont 0 in
the configuration file.
:dt.Include-file
:dd.A text-file to be included as is.
There will be no manipulation of the contents of this file.
This include-file may be all you need to obtain a fully custimised list.
For the IPF-list it may (and probably should) contain IPF tags.
:dt.Sub-Title
:dd.Up to 20 lines.
These are treated like the Pre-Title lines.
:dt.BottomTitle
:dd.Up to 20 lines as very last lines of the lists.
These follow my 'signature'.
The lines follow the same treatment as Pre-Title lines.
:edl.
:p.The BLOCK-title and Pre-, Sub-, and Botton-titles are used for all
reports identically, there is no such thing as an 'individual' title
specification for each report.
However the Include-file may be different for each report.
:note.Exceptions:
:ol.
:li.None of the above does apply to the BBS-list.
As it will generally be desirable to imbed (compiled) MECCA control
sequences in this type of lists, this report will include dedicated top
and bottom files (if available in the current default directory).
These files must be called DOWNSORT.HDR (header) and DOWNSORT.TRL
(trailer).
:li.The ORPHAN report will not contain any sort of user-titles.
:li.The FILES.bbs files will not use any of the title-specifications,
but may use an Include-file.
:eol.
:p.:hp2.Recommendation:ehp2.&colon. File-requestors appreciate a header
with a clear indication of the source of the reports.
Many Bulletin Boards use FILES or ALLFILES as 'magic' name,
but that is not very distinctive if you collect lists of different
boards!
:note.Specification details and samples can be found in DOWNSORT.CFG.
:erev refid=rev51.
.*
.*
:h3.Privileges with File Request
:p.If you run a mailer like BinkleyTerm, which makes a distinction
between 'unknown', 'known' and 'password-protected' users, you could
generate multiple download lists with different privilege indictor,
depending if you allow these categories to request different file
collections a sample of this kind of environment is given in
:hdref refid=sampl..
:p.This is not needed for DOWNSORT.BBS, since this file has imbedded
privilege control sequences for MAXIMUS users.
But you should specify a sufficiently high privilege for the BBS-list to
satisfy your most valuable users!
.* -------------------------------
:h2 id=sampl.Sample specifications and usage
:p.Assume you are runnung MAXIMUS with BinkleyTerm as front end mailer.
Suppose you make a distinction for file-requestors between Unknown, Known
and Password-Protected (e.g. corresponding to Disgrace, Normal and
Privileged MAXIMUS users).
.* ------
:h3.DOWNSORT specification sample
:p.You should have a specification like this:
:xmp scale='1.2'.
DOWNSORT bbs&colon.p new&colon.dnp all&colon.dnp 100
:exmp.
:p.In addition to or in place of the specifications in DOWNSORT.CFG,
this specification produces the following lists:
:ul.
:li.Orphan report (only if there are any orphans).
:li.DOWNSORT.BBS with 100 entries for MAXIMUS users of category Privil.
Users with a lower privilege will actually see a shorter list
if the file contains Privil entries.
:li.For file requestors of the magic filename FILES a list,
a list with all files
(with optional titles via DOWNSORT.CFG specifications):
:ul compact.
:li.DOWNSORT.A&tilde.D for UNKNOWN file-requestors
:li.DOWNSORT.A&tilde.N for KNOWN file-requestors
:li.DOWNSORT.A&tilde.P for Password Protected file-requestors
:eul.
:p.Note that each list is a complete list of what is available to
the user of the specific privilege class,
but your system will generally contain more files than listed for
UNKNOWN and KNOWN users!
:li.For file requests of the magic filename NEWFILES a list
of the 100 most recent additions to your system
(with optional titles via DOWNSORT.CFG specifications):
:ul compact.
:li.DOWNSORT.N&tilde.D for UNKNOWN file-requestors
:li.DOWNSORT.N&tilde.N for KNOWN file-requestors
:li.DOWNSORT.N&tilde.P for Password Protected file-requestors
:eul.
:p.Note that each list is 100 entries long, but the contents will
generally not be quite the same
:rev refid=rev51.
(depending on your privilege strategy).
:erev refid=rev51.
:eul.
:p.In general: files, which the requestor is not supposed to know about
due to his privilege status, will not be on his/her list!
:note.The counters on top of the lists indicate what your system has
available in total (including higher privileges), so a clever
user/file-requester may come up with the question how that is possible:
explain that he/she has to earn a higher privilege level!
.* ------
:h3.BinkleyTerm specification sample
:p.In Binkley.Cfg you should specify for requests of FILES:
:xmp scale='1.1'.
Avail Downsort.A&tilde.d
KnownAvail Downsort.A&tilde.n
ProtAvail Downsort.A&tilde.p
:exmp.
:p.Furthermore you may need to specify different OKFILEs:
.cp 5
:xmp scale='1.1'.
OKFile Download.N
KnownReqList Download.K
ProtReqList Download.P
:exmp.
.cp 16
:p.And in each of the appropriate filerequest authorisation files
you should specify the appropriate file-spec:
:fig place=inline width=page depth=1 frame=none.
:cgraphic scale='1.1'.
:on3270.
╔═══════════╦══════════════╦═══════════════╦═══════════════╗
║ in: ║ OKFile ║ KnownReqList ║ ProtReqList ║
║ ║ (Download.N) ║ (Download.K) ║ (Download.P) ║
║ for: ║ ║ ║ ║
╠═══════════╬══════════════╬═══════════════╬═══════════════╣
║ ..... ║ ......... ║ ........... ║ ........ ║
║ @NEWFILES ║ Downsort.N&tilde.d ║ Downsort.N&tilde.n ║ Downsort.N&tilde.p ║
║ @FILES ║ Downsort.A&tilde.d ║ Downsort.A&tilde.n ║ Downsort.A&tilde.p ║
║ ..... ║ ......... ║ ........... ║ ........ ║
╚═══════════╩══════════════╩═══════════════╩═══════════════╝
:off3270.
:ecgraphic.
:efig.
:p.This will result in sending of the appropriate NEW-list to every
requester of the magic filename: NEWFILES.
If you use the second magic filename, then the Avail-lines in
Binkley.Cfg are not needed, and you might prefer this way.
:p.Of course if the privilege level of all download area's is the same,
this construction is not needed,
but in that case it is unlikely that you have specified KnownAvail and
ProtAvail!
.* -----------------------------
:h2.Dependencies and restrictions
:ul.
:li.Applies to MAXIMUS CBCS 1.00 and 1.02.
:li.Requires OS/2 or DOS 3.0+.
:li.To convert the IPF-list into VIEW-able format (downsort.INF), the
IPF-Compiler under OS/2 is required.
:li.The input FILES.BBS files are assumed to contain only filename.ext
(the regular 8.3 format, no support for OS/2 1.2+ HPFS format),
the remainder of the line is considered as file description.
The filename should be left-aligned (start in position 1).
:p.If a privilege modifier (&caret.Px) is encountered in FILES.BBS
then 'x' will become the privilege of all subsequent files (it assumes
&caret.Px on a SEPARATE line, the REST OF THE LINE IS IGNORED!).
Heading, comments and blank lines in FILES.BBS are ignored.
The modified privilege might be higher (generally the case) or lower
than the area-privilege.
:eul.
.* -------------------------------
:h2.Wishlist
:p.DOWNSORT is not finished!
There are a number of wishes and requirements of users and myself to
include in future releases.
I list them below not in any particular order, but some seem to be more
important than others (but that differs from SYSOP to SYSOP).
And some are more easy to implement than others, and that depends mainly
on the author!
:ul.
:li.Follow the MAXIMUS development (changing AREA.DAT and other
structures), and support several versions simultaneously.
I'll try to make DOWNSORT independent of MAXIMUS-versions.
I'm thinking of parsing AREA.CTL, in stead of using AREA.DAT,
as suggested by Scott Dudley himself.
:li.Automatic removal of 'bad' files (like .BAK-files, obsolete files,
files that are not in FILES.BBS), maybe move them to a special
BAD&us.FILE directory.
:li.User-configurable options for:
:ul compact.
:li.week and month indicators
:li.indicator for continuation lines in wrapped descriptions
:li.font in AREA-header and Summary in ALL-list, and in FILES.BBS
:eul.
:li.Add &lbrk.selectable&rbrk. MECCA control in FILES.BBS, like in the
BBS-list.
:li.Logging to file in stead of console, obtaining a history file
of DOWNSORT usage.
:li.File-selection with MAXIMUS CBCS key/lock parameters in addition or
in stead of privilege levels.
:li.Selection of files in reports on area, or group of area's.
:li.Support for use of 'barricaded' areas and key/lock.
:li.Selection of NEW-list on basis of oldest date or time-period.
:li.Another list: with the format of IPF-list but the contents of
NEW-list.
:rev refid=rev51.
:li.Preserve comments and formattings of FILES.BBS files when
rebuilding these files.
:erev refid=rev51.
:eul.
.* -------------------------------
:rev refid=rev.
:h2.Known Problems
:p.Although I try to prevent the cause of them, there are problem reports:
:ul.
:li.Some unidentified characters somewhere between block- and sub-title.
:eul.
:erev refid=rev51.
.* ===============================================
:h1.Packaging
:p.DOWNSORT is distributed in 2 archives:
:ul.
:li.A file "DWNSRTxy.ZIP", containing all material you need to run
DOWNSORT, including documentation, formatted for browsing or printing
(formfeed is the only printer-control).
:li.A file "DWNSRSxy.ZIP", containing all SOURCE material.
:eul.
:note.'xy' is the version indication,
for example DWNSRT&VERSION.&SUBVERS..ZIP is the version
&VERSION..&SUBVERS. (RUN-time) package.
.* -----------------
:h2.RUN-time material
:dl tsize=20 termhi=3 compact.
:dt.WHATSNEW.&VERSION.&SUBVERS.
:dd.Summary of amendments to version &VERSION..&SUBVERS. of DOWNSORT.
:dt.DOWNSORT.EXE
:dd.Execution module for DOS and OS/2 (Family Application)
:dt.DOWNSORT.DOC
:dd.Documentation (this file!).
:dt.DOWNSORT.CFG
:dd.Sample configuration file.
This file contains comment lines with extensive instructions how to
specify the parameters in the file.
:dt.DOWNSORT.HDR
:dd.Sample BBS-list header.
You may use this header, which is only imbedded in the BBS-list,
to imbed text and/or MECCA-sequences.
A good candidate for the latter would be &lbrk.onexit&rbrk.,
which translates to &caret.OFpath.
See the sample DOWNSORT.HDR file!
:dt.DOWNSORT.TRL
:dd.Sample BBS-list trailer.
:dt.DOWNSORT.BMP
:dd.Bitmap for the IPF-list, to be included by the IPF compiler.
:rev refid=rev51.
:dt.DOWNSORT.INC
:dd.Sample Include-file for the reports, referenced in DOWNSORT.CFG.
:erev refid=rev51.
:dt.HPFSDATE.EXE
:dd.Program to display all three timestamps of a file on an HPFS volume,
and optionally reset the CREATION date to LASTWRITE date
(helpful after moving or copying of files).
Start the program without options to display command syntax and help.
:dt.README.1ST
:dd.The actual contents of the package (produced with PKUNZIP -V),
added to the ZIP-file after this was created with the foregoing files
of this archive.
This gives at least some authentication!
:edl.
.* ---
:h2.Source material
:dl tsize=20 termhi=3 compact.
:dt.DOWNSORT.C
:dd.Source of mainline and global variable definitions.
:dt.DOWNCOL.C
:dd.Source of data collection functions.
:dt.DOWNFNT.C
:dd.Source of font definition and formatting function.
:dt.DOWNPAR.C
:dd.Source of parameter processing functions.
:dt.DOWNRPT1.C
:dd.Source of output report functions (except what is in DOWNRPT2.C)
:dt.DOWNRPT2.C
:dd.Source of output report functions for ALL-list and IPF-list.
:dt.DOWNSRV.C
:dd.Source of miscellaneous services functions.
:dt.DOWNSORT.H
:dd.Header file, with external definitions of global variables.
:dt.DOWNSORT.SCT
:dd.Unformatted documentation file.
This file includes formatting tags in BOOKMASTER style for printing on
whatever devices are supported (like IBM page printers).
This format is compatible and can be formatted on an IBM host system
with DCF (SCRIPT) as well.
:rev refid=rev51.
The file can also processed by the IPF-compiler (just ignore the
warnings and error-messages!).
You may have to 'repair' the file of the Toolkit version 1.1 with symbols
(APSYMBOL.APS) in the IPFC directory: e.g. '&.titde.' should be
'&.tilde.', and all symbols should end with a full-stop (.), such as
'&.box34.'.
The IBM Toolkit 1.2/1.3 is distributed without these errors.
:erev refid=rev51.
:dt.AREA&us.MAX.H
:dd.Header file with union specification of AREA.DAT for different
versions of MAXIMUS (as far as the layout of AREA.DAT is concerned).
:dt.AREA&us.100.H
:dd.Header file with :hp2.guessed:ehp2. layout of AREA.DAT for MAXIMUS
CBCS version 1.00.
:dt.AREA&us.102.H
:dd.Header file with layout of AREA.DAT of MAXIMUS CBCS
version 1.02.
:dt.DOWNSORT.DEF
:dd.LINK definition file.
:dt.DOWNSORT.MAK
:dd.MAKE file.
:dt.README.1ST
:dd.The actual contents of the package (produced with PKUNZIP -V),
added to the ZIP-file after this was created with the foregoing files
of this archive.
This gives at least some authentication!
:edl.
.* ---------------------
:h2.Availability
:p.The most recent version of DOWNSORT is always downloadable and
file-requestable from Bulletin Board "PC-Square" of the Dutch IBM
employee PC club.
Search or request DWNSRT??.* to be independent of the version and
compression method!
:p.FIDO-net address: 2&colon.512/4; phone: 31-79-424107 (USR HST-DS).
:p.DOWNSORT is distributed in area SDSMAX of the international Shareware
Distribution System.
:p.There is a fair chance you may find a recent version on one of
the other bulletin boards, listed in :hdref refid=ause..
.* ===================================================================
:h1.Internals
.* ------
:h2.Development Environment
:p.DOWNSORT has been developed with IBM C/2 compiler version 1.1, under
IBM OS/2 Extended Edition 1.3 with Program Development Toolkit version
1.2/1.3 as COMPACT memory model.
:rev refid=rev51.
:p.DOWNSORT has been tested for MAXIMUS CBCS 1.00 and 1.02,
with the following Operating Systems:
:ul compact.
:li.IBM PC/DOS versions 4.0 and 5.0 (pre-release)
:li.IBM OS/2 versions 1.3 and 2.0 (pre-release)
:li.DOS-box of IBM OS/2 versions 1.3 and 2.0 (pre-release)
:eul.
:erev refid=rev51.
.* ---------------------------
:h2.Program Organisation
:p.The program is organised as follows:
:ul.
:li.Initialisation:
:ul compact.
:li.Read configuration file.
:li.Process commandline parameters.
:eul.
:p.The commandline parameters will override configuration file
parameters.
:li.Read AREA.DAT file to collect download pathnames (assumes AREA.DAT
is in current directory).
:rev refid=rev51.
:li.For all file-area's with a privilege not exceeding any list-request:
:erev refid=rev51.
:ul.
:li.Read subdirectory (with find-file-first/next function).
Take only Normal files: ignore directory entries, Hidden and System
files and volume labels.
Also ignore MAXIMUS-files with the following specifications: FILES.?BS,
*.BAK, DIR.?BS and SYSTEM*.?BS
:li.For all regular file-entries found in subdirectory:
:ul compact.
:li.Get filename.ext, attribute, date, time, size (timestamp will be
'last-time-written').
:li.Get file-description from FILES.BBS file.
The path to the FILES.BBS file is (1) obtained from the "ListFile"
specification in MAXIMUS AREA.DAT file, or (2) if not specified from the
"DownLoad" specification (among the download files).
:li.Get file privilege 1) from area, 2) from FILES.BBS file.
:rev refid=rev51.
:li.When no orphan reporting is required, then drop the orphan entries.
:erev refid=rev51.
:eul.
:eul.
:li.For the ORP-list:
:p.If any orphan found, and the orphan-report is requested, create the
orphan report, with the file-entries sorted on (1) area and (2)
filename.
:li.For the BBS-list:
:ul compact.
:li.Sort the files primarily on descending file-timestamp (and secundary
on file-name and area-code).
:li.Resort the first files on filename if requested.
:li.Create output file for sorted list of filenames, -descriptions, etc.
The file is placed in the current subdirectory (which generally will be
the MAXIMUS directory) with the name DOWNSORT.BBS.
:li.Copy a headerfile (for a customised MAXIMUS bulletin).
:li.Put files in formatted outputfile (filename, area#, date, size,
description), but only if description is found in FILES.BBS.
Skip files with privilege higher than commandline (or default)
parameter.
Precede each line with a privilege-control sequence (&caret.PLx string)
so that MAXIMUS users below the specified max-priv-level do effectively
see only the files they can download.
:li.Include a trailerfile in the outputfile (for a custimised Bulletin).
:li.Report non-listed files on standard output device (which might be
re-directed to printer or disk-file).
:eul.
:li.If requested, put the above file collection (also in reverse
date-sequence) in DOWNSORT.N&tilde.p with similar contents and layout as
DOWNSORT.BBS, but without BBS-control sequences, and without including a
header and trailer file.
Produce a list for the default privilege (HIDDEN), or one for each
specified privilege.
:li.If requested, re-sort files on area and then filename, and create
DOWNSORT.A&tilde.p, containing all files (respecting the privilege
restrictions!).
Area's with zero files within the applicable privilege limit will not
be listed at all (will seem non-existing!).
Produce a list for the default privilege (SYSOP), or one for each
specified privilege.
:p.At the end of the list, an area summary report is generated.
:li.If requested, re-sort files on filename only, and create
DOWNSORT.GBL.
:li.If requested, re-sort files on area, privilege and filename, and
create for each area a FILES.BBS-type of file.
:eul.
:p.NOTE: the program firstly reads a directory for existing files
(not Hidden- or System-files, and not Subdirectory or Volumelabel),
and then reads FILES.BBS to assign a description to each file.
This means:
:ul compact.
:li.If more than 1 matching file-specification in FILES.BBS of the
involved area is found (note that wild-card specifications in FILES.BBS
are supported!), than the :hp2.first matching description:ehp2. from
FILES.BBS will appear in the lists
(new in version 4.5, was 'last' previous versions).
:li.Files for which no description is found in FILES.BBS will get
"---no description available---"
(or the replacement string you specified in DOWNSORT.CFG)
in the user reports.
:li.Files for which no matching filename in FILES.BBS is found will
be listed in the Orphan report (DOWNSORT.ORP).
:p.In special cases this might become a very large list.
For example if you collect files in a single directory for different
area's, all the files of 'the other' areas are reported as orphan.
This will happen for every area, so each file might even be reported
many times as orphan!
Since the Orphan-list is now optional (from version 5.0 on), this list
can be suppressed.
:p.Filenames of Orphans appear only in the other reports when the
FileList request explicitly specifies the Hidden privilege.
:eul.
.* -----------
:h2.Main Data Organisation
:p.Data structure for access to file information via:
:ol compact.
:li.array of file-pointers (for file-sort!)
:li.pointerchain in file-info structures
:li.file structure contains pointer to file-description
:li.file-structure contains pointer to area-information
:li.Array of area-information
:eol.
:p.The structures are shown in :figref refid=data..
:fig id=data place=inline width=page depth=1 frame=none.
:cgraphic scale='1.1'.
:on3270.
╔══════╗
║ dm ║
╚══════╝
│ Array of pointers to structures with file info
│ ╔═══════════╦════════════╦═════════════ . . . ══════╗
(1) └─────>║ *file&lbrk.0&rbrk. ║ *file&lbrk.1&rbrk. ║ *file&lbrk.2&rbrk. ║
╚═══════════╩════════════╩═════════════ . . . ══════╝
│ │ │
(2) v v v
╔══════╗ ╔══════╗ ╔══════╗ ╔══════╗
║ ca ║ ──> ║ next ║ ──> ║ next ║ ──> ║ next ║ ──> . . .
╚══════╝ ╠══════╣ ╠══════╣ ╠══════╣
(first- ║ file-║ ║ file-║ ║ file-║
element) ║ info ║ ║ info ║ ║ info ║ . . .
║ &lbrk.0&rbrk. ║ ║ &lbrk.1&rbrk. ║ ║ &lbrk.2&rbrk. ║
╚══════╝ ╚══════╝ ╚══════╝
│ │ │ │wildcards│ │
│ └──┐ │ └──┐ │ │
│ │ │ ┌──────────┘ │
(3) v │ v v │ ┌──────┘
╔══════╗ │ ╔══════╗ │ │
║file- ║ │ ║file- ║ │ │(files of
║descr ║ │ ║descr ║ │ │ same area) . . .
╚══════╝ │ ╚══════╝ │ │
│ │ │
(4) v v v
╔════════════╦═════════════╦════════ . . . ══════╗
(5) ┌────────>║ area&lbrk.0&rbrk. ║ area&lbrk.1&rbrk. ║ ║
│ ╚════════════╩═════════════╩════════ . . . ══════╝
│ array of structures of download info
╔══════╗
║ area ║
╚══════╝
:off3270.
:ecgraphic.
:figcap.Schematic overview of DOWNSORT's in-storage database.
:efig.
:note.The area-array cannot be sorted itself: this would invalidate the
pointers in the file-information records!
:p.The block character image is basically a 10x7 matrix
(10 vertical and 7 horizontal 'pixels').
:rev refid=rev51.
The pixel-array takes two rows at a time, so that each character
can be represented with 5 rows of 7 horizontal 'double-pixels'.
:erev refid=rev51.
Each pixel is displayed as a solid block.
:fig place=inline width=page depth=1 frame=none.
:cgraphic scale='1.1'.
:on3270.
1 2 3 4 5 6 7
╔═╦═╦═╦═╦═╦═╦═╗
║-║-║-║-║-║-║-║ line 1 (lower + upper)
╠═╬═╬═╬═╬═╬═╬═╣
║-║-║-║-║-║-║-║ 2 (lower + upper)
╠═╬═╬═╬═╬═╬═╬═╣
║-║-║-║-║-║-║-║ 3 (lower + upper)
╠═╬═╬═╬═╬═╬═╬═╣
║-║-║-║-║-║-║-║ 4 (lower + upper)
╠═╬═╬═╬═╬═╬═╬═╣
║-║-║-║-║-║-║-║ 5 (lower + upper)
╚═╩═╩═╩═╩═╩═╩═╝
:off3270.
:ecgraphic.
:efig.
:p.Each line is represented by a structure of seven 3-bit fields
Each 3-bit field represents a basic element:
:xmp scale='1.1'.
value char description
0 (blank)
1 &BOXBOT. lower half
2 &BOXTOP. upper half
3 &BOX. lower+upper halves
4 &box34. gray pattern
5 &BOXLEFT. left part of upper and lower half
6 &BOXRIGHT. right part of upper and lower half
7 &box14. gray pattern
8 &box12. gray pattern for not-supported characters
:exmp.
:p.The pitch is variable ('proportional font': a variable number of
horizontal pixels).
Three fonts are provided with different character-image and size:
:ol compact.
:li.6x5 (three lines of max 5 characters)
:li.10x7 (five lines of max 7 characters)
:li.8x7 (four lines of max 7 characters)
:li.10x7 (reverse video image of the 8x7 font)
:eol.
:p.Not all ASCII characters are represented in the font tables!
.* -----------
:h2 id=perf.Storage and Performance
:p.As a rough estimate of the memory requirements of DOWNSORT,
use sum of the following elements:
:ul.
:li.Program: about 70KB
:li.Each area: 300 Bytes
:li.Each file: 64 Bytes for each file (excl. file descriptions)
:li.The sum of the description texts (on average 80 Bytes?)
:eul.
:p.There is a theoretical limit on the number of files that can be
processed by DOWNSORT: about 16000 files.
I suppose you'll reach other limits first, for example stack-space.
DOWNSORT has been built with a 'guess' about needed stack space.
The author would appreciate to receive a report for a better estimate.
:p.Processor performance was an issue for large file-area's before
version 4.5 of DOWNSORT in the data-collection process.
That has been partly rewritten in version 4.5 and significantly improved.
Fastest execution will always be obtained when the input FILES.BBS is
already sorted on filename.
.* --------------------------------
:appendix.
:h1 id=ahis.History of changes
:p.The paragraphs below show a brief history of changes in DOWNSORT
(most recent revisions on top of list!).
:p.DOWNSORT for MAXIMUS CBCS was developed from an OPUS equivalent
(by the same author).
Its pre-MAXIMUS history is not really important here and therefore has
been omitted.
However the name DOWNSORT has been maintained, so to prevent confusion,
the version number is inherited (the last version for OPUS was 3.1).
.*
:rev refid=rev51.
:h2.Version 5.1
:ul compact.
:li.Since the ORPhan report is optional (changed with version 5.0),
orphan entries could and now will be removed from internal storage
during the information collection phase of DOWNSORT, but
:hp2.only when no orphan-list is requested:ehp2.!
This is especially useful for the situation where a single large
directory contains the files of several area's, and whereby the file
descriptions are contained in different FILES.BBS files.
Normally this will result in reporting lots of duplicate orphans
(according to the definition of 'orphan' in DOWNSORT!).
With this change memory utilisation is lower and sorting faster.
:li.Another change of this kind: area's with a privilege exceeding
any reporting privilege are not scanned anymore.
Apart from lower memory utilisation, this might be useful for CDROM and
slow disk(ette) systems.
:li.The maximum number of Top-, Sub- and Bottom-Title lines has been
extended to 20.
:li.In addition all lists may now include a 'logo'-file with a new -I
parameter on the individual report request specification (see sample
DOWNSORT.CFG).
The file will be copied into the list without any editing or
translation.
It will be positioned directly behind the block-title and before the
subtitle (if any).
For example: you may include your BBS-logo or a picture of your system
configuration, or anything else you want to tell the file-requestors of
FILES, ALLFILES and/or NEWFILES.
The IPF-list may also include IPF tags, with artwork, etc.
It may even include other files itself!
For FILES.BBS the contents of this Include-file will immediately follow
the 'standard' header.
:li.All block-fonts have now a new special character <`> (reversed
quote), which will be 'printed' as blank (space) with :hp2.half:ehp2.
the width of a normal character.
This is useful for fine-alignment (e.g. manually centering) the
BLOCK-title.
:li.The chapter on 'titles and headers' has been rewritten to clarify
the use of all title-options, :hp2.please read it!:ehp2..
:li.In the SUMMARY of ALL- and IPF-lists the areas themselves
are not sorted anymore, but presented in sequence of AREAS.CTL
specification.
This is based on the assumption that the file area's are in some kind of
'natural' order in AREAS.CTL (or maybe it is time to do that now!).
:li.Descriptions in FILES.BBS are now (again) aligned on column 14 of
the FILES.bbs file records.
:li.IPF-list again a little more user-friendly (linking of area's).
:li.A number of improvements have been applied to the executiontime
messages (when running in VERBOSE mode).
:eul.
:erev refid=rev51.
.*
:h2.Version 5.0
:ul compact.
:li.Improved IPF-formatting: more colorful, builtin word-wrapping of
VIEW used for file descriptions (better VIEWable under OS/2 1.3!).
It should now also compile without errors/warnings.
Compiling (with IPFC) takes significantly longer however!
:li.The IPF-list of large filearea's (>200 files) split into parts of
200 files to prevent files being left unlisted.
:li.Top-level title in FileLists shows file-count and byte-count as
available within the privilege of the list.
Thus it indicates what is really AVAILable to the user!
Area-count omitted in lists which are not area-oriented.
:li.ORPHAN report made OPTIONAL (must be specified to get it!).
:eul.
.*
:h2.Version 4.9
:ul compact.
:li.Added a new list-format: IPF-list, similar to ALL-list, but meant to
be made a VIEWable file ('book') under OS/2 Presentation Manager.
:li.Sourcefile DOWNRPT.C splitted into 2 parts.
:li.Correction in FILES.BBS header (to prevent the "offline" msg).
:li.Now also FILES.BBS output can be kept in original sequence with the
K(eep)-option.
:li.Added the X-option: all 'written' privilege indications in the lists
can now be suppressed: the user is then not aware of any
privilege-system!
:li.Header-lines of all lists now more consistent in sequence.
:li.The 'I'- and '1'-characters in fonts 3 and 4 have been widened to 5
colums (was 3 colums, but that looked too 'narrow').
:li.The documentation has been extended with a list of Bulletin Boards,
of which the SYSOPs have reported being a regular user of DOWNSORT.
:li.Distribution has been changed: run-time and source material now in a
separate archive files (DWNSRTxy.ZIP and DWNSRSxy.ZIP).
:eul.
.*
:h2.Version 4.8
:ul compact.
:li.A 'KEEP' parameter (-K) added to allow the files to remain in
original sequence of FILES.BBS.
This option is now only valid for ALL-list (later for FIL-list too).
:li.Documentation change: for multi-line file descriptions a
continuation line must start with at least 1 blank-character,
followed by at least 1 significant (non-blank) character.
:li.Repaired bug in sort on filedate for FIL-lists.
:eul.
.*
:h2.Version 4.7
:ul compact.
:li.Sorting of files on HPFS volumes (OS/2 1.2) now takes into account
the file CREATION-date (= arrival date on your system).
Sort will take the most recent of Creation and LastWrite.
The 'old fashioned' LastWrite date (indicating the age of the file)
is displayed in the lists!
This feature is only effective under OS/2 from release 1.2 for files
on an HPFS volume.
:li.Use of DOSOPEN() from OS/2 Program Development Toolkit (allows for
better multi-session and LAN support).
:li.New font added: reverse video image of font3,
and related changes in font generation function.
:li.Added separation lines in FILES.BBS like in ALL-list.
:li.Tiny adjustment to date formatting: year 2000 and later will be
displayed as 2-digit numbers.
:eul.
.*
:h2.Version 4.6
:ul compact.
:li.Downsort will try to locate and read a configuration file allowing
even more processing options
(by default DOWNSORT.CFG in current directory).
An extensively documented sample is accompanying the DOWNSORT package.
No additional document-reading needed to run DOWNSORT for the first time.
The introduction of this feature makes some commandline parameters
superfluous, and allows more flexibility, like:
:ul compact.
:li.In addition to a number of global parameters,
each list has a 'local' set of formatting parameters for
sort-sequence, description wrapping, title-font, maximum number of
entries (NEW and BBS only).
The individual parameters can be set only via the configuration file.
:li.Specification of AREA.DAT and "title" not possible anymore on the
commandline, now only by means of the configuration file.
:li.A "@filespec" commandline option now used for specification of
the configuration file (makes the use of different files for different
purposes possible).
:eul.
:li.Multiline FILES.BBS input now supported.
Automatic conversion to long descriptions provided when requesting
FILES.BBS (re-)creation.
:li.Multiple GBL-lists can now be generated, like ALL-list.
Difference between ALL-list and GBL-list is only the grouping by
in area's, and the area-summary in ALL-list.
SYSOP may decide which of both serves the users best.
:li.User supplied pre-title, sub-title and bottomlines now supported
for NEW, ALL and GBL-lists,
as well as replacement text for '---no-description---' and
'---orphan---' in the lists.
:li.BLOCK-title font user-configurable and BLOCK-title can now be
suppressed.
:li.NEW-list and GBL-list have an additional header-line telling the
maximum file-privilege shown in the list.
:li.FILES.BBS has now column header, and a user-specified privilege limit
applies also to FILES.BBS
(orphans now only listed when explicitly requested with 'Hidden').
:li.The HELP-screen is now only shown :hp2.on request:ehp2. via a
commandline parameter (-H).
:eul.
.*
:h2.Version 4.5
:ul compact.
:li.FILES.BBS-files may be (re-)created now in DOWNSORT-style
(like the ALL-list format).
Read carefully the information about this option in the
report description!
:li.An ORPHAN-report is now produced always (not requestable) and
independent from other reports.
It replaces the reporting of ORPHANs to the console formerly done during
creation of the BBS-list.
:li.The BBS-list is no longer produced by default, it should be
specifically requested now, like the other user-reports.
:li.The BBS-list and NEW-list may now be sorted on filename,
and for that reason also these lists will have an age indicator 'week'
or 'month' old appended to the file date.
:li.'Verbose' and 'Quiet' operating mode are possible now: many more or
much less console messages with one of these specifications,
than regularly.
:li.Performance improvement obtained in data collection process,
significant especially for large area's.
:li.Filename matching process changed (one of the reasons of the
performance improvement): :hp2.first:ehp2. matching filename is
used now to assign the file description to a file.
:li.Title block-font is now proportional, and two fonts are added.
The fonts are not (yet) user selectable.
:li.A path to the appropriate AREA.DAT file may be specified now
(@path).
:li.The possible specification of "ListFile" in AREA.CTL is recognised
now (in stead of assuming FILES.BBS in the download directory).
:li.Added display of an "I-am-busy" indicator during the
collection of file information (processing FILES.BBS input).
:li.Added display of date and time of report-creation to bottom of
file lists (except FILES.BBS files), and also the total elapsed time on
console.
:li.Fixed bug in detection of newest file, which in rare situations
pointed to a file outside the privilege group.
:li.Added HELP-screen when no commandline parameters specified, or on
request (-H commandline parameter).
:li.'Signature' at bottom of lists extended.
:li.Documentation extended for all the new features, and a little
re-organised.
:li.Internal data structure for file-information changed for improved
storage utilisation.
:li.Time has come to split source into several modules!
:eul.
.*
:h2.Version 4.4
:ul compact.
:li.Support for different versions of MAXIMUS (1.00 and 1.02), with
respect to the layout of AREA.DAT.
:li.Multi-line file descriptions now supported, with word-wrap and an
option to select or deselect it in different reports.
:li.Extended AREA-header in ALL-list with area-privilege indicator,
and latest acquisition (date and file-spec).
:li.Added indicators '*' and '+' in GBL- and ALL-list for files of
1-week and 1-month old respectively.
:li.Added "--- no description available ---" in lists if filename found
in FILES.BBS, but there is no description there.
:li.Added "****** ORPHAN *******" in description field of
files, for which there is no entry in FILES.BBS.
:li.Files that are reported to the console as "not listed", now also
display the area, (pseudo-) privilege and file description (or "no
description" or "ORPHAN" whatever is applicable).
:li.Changed default file-report privilege into SYSOP.
Hidden files will not show up, unless specifically asked for!
:li.More characters supported as BLOCK-characters (including '/' and
'\').
:li.Fixed a bug in routines for NEW-, BBS- and ALL-list, which
occasionally gave addressing violations (in the OS/2 version).
:li.A related change in the data structure of the file-information for
the file-description decreases storage utilisation, taking advantage
of wild-card specifications in FILES.BBS as supported by MAXIMUS.
:li.Fast growing wishlist added to documentation!
:eul.
.*
:h2.Version 4.3
:ul compact.
:li.GBL-list added: a complete list of the download base (back from 4.0
and earlier versions of DOWNSORT, where it was called ALL!).
:li.An AREA-summary report has been added to ALL-list.
:li.ALL-list now also displays total bytecount per area.
:li.A default title will be generated if none is specified.
:li.Routine for generating block routines replaced.
:li.Block character '/' (slash) replaced by '|' (vertical bar).
:eul.
.*
:h2.Version 4.2
:ul compact.
:li.DOWNSORT.BBS and DOWNSORT.NEW are not produced any longer by
default.
Each list-type must now be specifically requested by BBS, NEW, or
ALL on the commandline.
:li.Multiple ALL-lists and NEW-lists may be produced now.
Each of these may contain files of different (maximum) privilege level.
This makes it possible to have overviews for different classes of users.
:li.A report title for the ALL- and NEW-lists may be specified, and will
be printed in BLOCK-characters.
:li.A remark has been added to the top of DOWNSORT.BBS that the list may
seem shorter due to privilege restrictions.
:li.Longer file-description where there is space for it (ALL-list).
:li.Requirement of filenames in FILES.BBS to be UPPERcase dropped.
:li.Documentation extended and re-formatted.
:li.Some more re-shuffling of code (for maintenance purposes)!
:eul.
.*
:h2.Version 4.1
:ul compact.
:li.Bug-repairs in filename-matching routine.
:li.SORT changed for DOWNSORT.ALL: sort on name within area, gives an
alphabetical list per download area.
:li.File descriptions now left aligned, regardless its position in
FILES.BBS.
:li.Group-title (of file-area) copied from AREA.DAT in ALL.
:li.Files excluded from the lists are now more generally: FILES.?BS,
DIR.?BS and SYSTEM*.?BS
:li.Parameter added to hide files above a maximum privilege-level.
:li.Files without description are treated as Hidden, these will appear
in the lists when 'H' is selected (note: by default!).
:li.Improved sort organisation (pointers in stead of structures).
:li.Minor changes and additions to lists (beautification?).
:li.Some minor internal re-organisation.
:eul.
.*
:h2.Version 4.0
:ul compact.
:li.New setup for MAXIMUS CBCS Bulletin Board environment, this version
does not support OPUS' file system!
:li.Support of non-numeric (two-character) area code.
:li.Support of wild-characters in the file-name part of the records in
the description-files (FILES.BBS), as allowed by MAXIMUS.
:li.The file DOWNSORT.NEW (not ".TXT") will be produced always (error in
previous documentation), but now without TXT2COM formatting characters,
since there is not (yet) a suitable alternative under OS/2.
:eul.
.* =============================
:h1 id=ause.Who use DOWNSORT?
:p.PC-Square may be considered as the home-base of DOWNSORT.
The most recent version is always available there
(file-requests between 07:00 and 24:00 local time).
:xmp keep=off.
:hp2.
PC-Square Marcel Stikkelman Zoetermeer, Netherlands
2&colon.512/4 31-79-424107
:p.The following SYSOPs have reported using DOWNSORT on their
respective boards:
OS/2-MANiA Emmanuel Sandorfi Paris, France
2&colon.320/5 33-1-64090640
:rev refid=rev51.
OS/2 TASK BBS Rene Carlsen Skagen, Denmark
2&colon.231/85 45-98451070
Paradigmus Maximus John Taylor London, UK
2&colon.253/68 44-81-566-5393
:erev refid=rev51.
Fernwood Emitt Dove Branford CT, USA
1&colon.141/209 1-203-483-0348
:rev refid=rev51.
Bell's Theorem Jeremy Buhler Houston TX, USA
1&colon.106/7674 1-713-777-0633
:erev refid=rev51.
OS/2 Shareware Pete Norloff Fairfax VA, USA
1&colon.109/347 1-703-385-4325
Singing Bear John Tarbox Wilmington DE, USA
1&colon.150/130 1-302-984-2238
La Jungle BBS Stephane Seguin Quebec, Canada
1&colon.163/116 1-819-595-4917
:rev refid=rev51.
3M Australia Graham Stair Sydney, NSW Australia
3&colon.711/409 61-2-498-9184
:erev refid=rev51.
:ehp2.
:exmp.
:p.I have received reports from others.
Too many for this list, which is just meant to point to a system
in your neighbourhood(?).
You may either logon to one of these boards, or perform a file-request
of 'FILES' or 'ALLFILES' to get an impression of DOWNSORT's
capabilities.
.* =============================
:h1 id=acfg.Sample Configuration File
:xmp keep=off.
.im \c2\downsort\downsort.cfg
:exmp.
:euserdoc.