 
 SysOpsMichael Disabato
 Automatic E-Mag Updating (ReadRoom)The White Star Line
 

   This article describes how to automatically import the wonderful
   electronic magazines that are distributed via PostLink NetFiler
   services into the ReadRoom Door.  In addition, the process copies
   the files to your electronic magazine directory and updates your
   files list.  Last, but not least, it will send you a message in the
   conference of your choice and update a bulletin.
   
   The first step is to get on the monthly distribution list from your
   SysOp.  PostLink can send you files along with your message packets.
   Depending on your configuration, Postlink can put the files in whatever
   directory you wish.  My parameter in POSTLINK.CFG is:
   
	RECEIVED-FILES-DIR=E:\DOORS\POSTLINK\FILES\
   
   Once the file is transmitted, what do you do with it?  We'll take
   this step by step.  The complete batch file is included.  Feel free
   to modify it for your system.
   
   First, we must make sure we are on the right drive and in the right
   directory.
   
	    e:
	    cd \doors\postlink\files
   
   Next, test for the existence of the file.
   
	    if not exist SM*.ZIP goto Skip_SM
   
   If it finds a new file, delete the old one from the ReadRoom
   directory, copy the new one to the ReadRoom and Electronic Magazine
   directories, and delete it from the PostLink directory.
   
	    del e:\doors\readroom\SM*.ZIP
	    copy SM*.ZIP e:\doors\readroom 
	    copy SM*.ZIP d:\emags 
	    del e:\doors\postlink\files\SM*.ZIP
   
   You come here if no file was found.
			 
	    :Skip_SM
   
   The above section is repeated for each publication you plan to receive.
   
   Now, we change to the ReadRoom directory.
   
	    cd \doors\readroom
   
   Run the IMPORT program.
   
	    import readrm1.cnf
   
   Run LSTRELAY.  This is the program that imports a message and
   updates your bulletin.
   
	    lstrelay /F1 lstrelay.cfg
   
   That does it for the import process.  The next steps are specific
   for TriBBS systems.  If you're running something else, you'll have
   to find the equivalent utility and make the translation.
   
   Change to the drive and directory where your publication files are
   kept.
   
	    d:
	    cd \emags
   
   The next line adds the file names to the directory list and reads
   the FILE_ID.DIZ file for the description.
   
	    fileslst
   
   This last section re-indexes the files listings and converts them to
   the binary format required by TriBBS.
   
	c:
	cd \tribbs
	asctobin /F:8
	makeidx /F:8
	cd\
   
   That's it, folks!  Hope this helps you out.  It has simplified 
   my READROOM import process quite a bit.
   
   Mike
   
   
       ===========================================================
       What follows is the batch file in its entirety.
       ===========================================================
       
REM Batch file to import new editions of electronic
REM magazines into ReadRoom from PostLink

e:
cd \doors\postlink\files

if not exist CTM*.ZIP goto Skip_CTM

del e:\doors\readroom\CTM*.zip
copy CTM*.ZIP e:\doors\readroom
copy CTM*.ZIP d:\emags
del e:\doors\postlink\files\CTM*.ZIP
		      
:Skip_CTM

if not exist SUN*.ZIP goto Skip_SUN

del e:\doors\readroom\SUN*.ZIP
copy SUN*.ZIP e:\doors\readroom 
copy SUN*.ZIP d:\emags 
del e:\doors\postlink\files\SUN*.ZIP
		      
:Skip_SUN

if not exist RAH*.ZIP goto Skip_RAH

del e:\doors\readroom\RAH*.ZIP
copy RAH*.ZIP e:\doors\readroom 
copy RAH*.ZIP d:\emags 
del e:\doors\postlink\files\RAH*.ZIP
		      
:Skip_RAH

if not exist SM*.ZIP goto Skip_SM

del e:\doors\readroom\SM*.ZIP
copy SM*.ZIP e:\doors\readroom 
copy SM*.ZIP d:\emags 
del e:\doors\postlink\files\SM*.ZIP
		      
:Skip_SM

if not exist MNEWS*.ZIP goto Skip_MNEWS

del e:\doors\readroom\MNEWS*.ZIP
copy MNEWS*.ZIP e:\doors\readroom 
copy MNEWS*.ZIP d:\emags 
del e:\doors\postlink\files\MNEWS*.ZIP
		      
:Skip_MNEWS

if not exist RUBY*.ZIP goto Skip_RUBY

del e:\doors\readroom\RUBY*.ZIP
copy RUBY*.ZIP e:\doors\readroom 
copy RUBY*.ZIP d:\emags 
del e:\doors\postlink\files\RUBY*.ZIP
		      
:Skip_RUBY

if not exist PIM*.ZIP goto Skip_PIM

del e:\doors\readroom\PIM*.ZIP
copy PIM*.ZIP e:\doors\readroom 
copy PIM*.ZIP d:\emags 
del e:\doors\postlink\files\PIM*.ZIP
		      
:Skip_PIM

if not exist SSNR*.ZIP goto Skip_SSN

del e:\doors\readroom\SSNR*.ZIP
copy SSNR*.ZIP e:\doors\readroom 
copy SSNR*.ZIP d:\emags 
del e:\doors\postlink\files\SSNR*.ZIP
		      
:Skip_SSN

if not exist TC*.ZIP goto Skip_TC

del e:\doors\readroom\TC*.ZIP
copy TC*.ZIP e:\doors\readroom 
copy TC*.ZIP d:\emags 
del e:\doors\postlink\files\TC*.ZIP
		      
:Skip_TC

if not exist TRI*.ZIP goto Skip_TRI

del e:\doors\readroom\TRI*.ZIP
copy TRI*.ZIP e:\doors\readroom 
copy TRI*.ZIP d:\emags 
del e:\doors\postlink\files\TRI*.ZIP
		      
:Skip_TRI

if not exist DBM.ZIP goto Skip_DBM

del e:\doors\readroom\DBM*.ZIP
copy DBM*.ZIP e:\doors\readroom 
copy DBM*.ZIP d:\emags 
del e:\doors\postlink\files\DBM*.ZIP
		      
:Skip_DBM

cd \doors\readroom

import readrm1.cnf

lstrelay  /F1 lstrelay.cfg

d:
cd \emags
fileslst

c:
cd \tribbs
asctobin /F:8
makeidx /F:8
cd\


Note:
Contact Michael Disabato through the Pen and Brush Network (P&BNet)
any conference. Postlink routing code ->5464 or ->WHITESTAR
Or call his BBS!      
		      The White Star Line, Park Ridge, IL
		      (708) 823 - 4814 14.4 v.32 v.42 fax

				  -end-
		      Copyright (c)1994 Michael Disabato
		      You are free to use the batch file
		      included in this article on your BBS. 
