LSTSRV-L Archives

LISTSERV Site Administrators' Forum

LSTSRV-L

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Topic: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Greg Kroll <[log in to unmask]>
Wed, 30 Oct 1996 11:26:29 EST
text/plain (45 lines)
Chris,
 
  I just poked around a little and if you are doing this from VM, here is
an old, quickie Rexx exec I used to use to perform this function.  The
advantage of using an exec is the ability to delete as many log files
as you want pretty easily.  For what it's worth here it is.
 
+++++++++++++++++++++++++++++++
/* Deletes files for a LISTSERV list, to use:
     1) retrieve a copy of the FILELIST with: index <listname>
     2) delete all lines from this retrieved file EXCEPT for those lines
        listing the file(s) to be deleted.
     3) use this edited file as input to this exec, along with either
        your "personal" LISTSERV password or the password associated
        with the list for this FILELIST.  The syntax is:
          lsvdfile <filelist-file-name> <password>
     4) this exec will read the edited filelist and create a one line
        mail file with a LISTSERV put command to delete the file.
*/
trace e
arg filelist_fn list_pw .
if list_pw = '' then do
  say 'You must supply the FILELIST name and appropriate password, in ',
      'that order!'
  exit 9999
end
'EXECIO 1 DISKR 'filelist_fn' FILELIST * (VAR LINE'
 
do while (rc = 0)
  parse var line file_to_delete_fn file_to_delete_ft trash
  put_command = 'PUT 'file_to_delete_fn file_to_delete_ft filelist_fn,
               ' PW='list_pw
  'EXECIO 1 DISKW $$LSVT$$ $$MAIL$$ A 1 (FINIS VAR PUT_COMMAND'
  'EXEC MAIL LISTSERV (NOLOG NOEDIT NOPROMPT FILE $$LSVT$$ $$MAIL$$ A'
  'EXECIO 1 DISKR 'filelist_fn' FILELIST * (VAR LINE'
end
 
'ERASE $$LSVT$$ $$MAIL$$ A'
 
exit
 
 
--Greg Kroll
  Virginia Tech Computing Center

ATOM RSS1 RSS2