(DEFINE-FILE-INFO PACKAGE "INTERLISP" READTABLE "INTERLISP" BASE 10) (FILECREATED " 1-Apr-92 18:06:57" |{PELE:MV:ENVOS}INTERNAL>LIBRARY>ARCLEANUP.;8| 14846 changes to%: (FNS AR.CLEANUP.DO.SUMMARIES) previous date%: "30-Mar-92 10:45:38" |{PELE:MV:ENVOS}INTERNAL>LIBRARY>ARCLEANUP.;6| ) (* ; " Copyright (c) 1984, 1985, 1986, 1987, 1988, 1989, 1990, 1992 by Venue & Xerox Corporation. All rights reserved. ") (PRETTYCOMPRINT ARCLEANUPCOMS) (RPAQQ ARCLEANUPCOMS [(FILES AREDIT ARINDEX) (COMS (* ; "The main CLEANUP code") (FNS AR.CLEANUP AR.GET.NUMS.FROM.TDS AR.PRINT.AND.IP.FILE AR.QUERY.PRINT.AND.IP.FILE) (* ; "Special versions of CLEANUP") (FNS AR.CLEANUP.DO.SUMMARIES AR.CLEANUP.REDO.SUMMARIES AR.CLEANUP.NO.SUMMARIES)) (COMS (* ;  "List of names to generate summaries for") (INITVARS (AR.CLEANUP.HACKER.NAMES '(Bane Gadener Masinter Mitani Osamu Porter Prolog Shimizu Sybalsky vanMelle Welch)) (AR.CLEANUP.SORT.ORDER '(System%: Subsystem%: Status%: Priority%: Impact%:)) (AR.SUMMARY.DIRECTORY "{AR:MV:Envos}Summaries>")) (P (CL:PROCLAIM '(CL:SPECIAL AR.CLEANUP.HACKER.NAMES AR.CLEANUP.SORT.ORDER AR.SUMMARY.DIRECTORY]) (FILESLOAD AREDIT ARINDEX) (* ; "The main CLEANUP code") (DEFINEQ (AR.CLEANUP [LAMBDA (UPDATE.FLG INDEX.LOCAL.DIR SUMMARY.FLG SUMMARY.LOCAL.DIR) (* ; "Edited 7-Dec-89 18:25 by jds") (PROG ([LOCAL.AR.INDEX.NAME (AND INDEX.LOCAL.DIR (CONCAT INDEX.LOCAL.DIR 'AR.INDEX] INDEX.WINDOW) (COND (LOCAL.AR.INDEX.NAME (printout T "copying old AR index to " LOCAL.AR.INDEX.NAME "...") (COPYFILES AR.INDEX.DEFAULT.FILE.NAME LOCAL.AR.INDEX.NAME '>A) (printout T "done" T))) [COND (UPDATE.FLG (PROG ((SAVED.TDS.NAME (CONCAT AR.INFO.FILE.NAME '-PROCESSED)) NUMBERS INDEX.WINDOW) (COND ((NOT (INFILEP AR.INFO.FILE.NAME)) (printout T "No TDS file --- AR update aborted" T) (RETURN))) [SETQ NUMBERS (SORT (CL:REMOVE-DUPLICATES (while (INFILEP AR.INFO.FILE.NAME) join (until (NLSETQ (RENAMEFILE AR.INFO.FILE.NAME SAVED.TDS.NAME)) do (printout T "Can't rename TDS file --- trying again" T) (BLOCK 5000)) (AR.GET.NUMS.FROM.TDS SAVED.TDS.NAME] (COND ((NULL NUMBERS) (printout T "No numbers found in TDS file --- AR update aborted" T ) (RETURN))) (printout T "Will update AR numbers:" T NUMBERS T) (* ;; "update AR index") (SETQ INDEX.WINDOW (CREATEW (CREATEREGION 400 200 400 65) "old index")) (AR.QFORM.GROUP.CREATE (OR LOCAL.AR.INDEX.NAME AR.INDEX.DEFAULT.FILE.NAME) INDEX.WINDOW) (printout T "updating AR index....") (AR.INDEX.UPDATE INDEX.WINDOW NUMBERS) (CLOSEW INDEX.WINDOW) (printout T "done" T) (COND (LOCAL.AR.INDEX.NAME (printout T "deleting old AR index from " LOCAL.AR.INDEX.NAME "...") (DELFILE LOCAL.AR.INDEX.NAME) (printout T "done" T "copying new index to file server..." (COPYFILE LOCAL.AR.INDEX.NAME AR.INDEX.DEFAULT.FILE.NAME) "done" T] (if SUMMARY.FLG then (SETQ INDEX.WINDOW (CREATEW (CREATEREGION 660 100 350 132))) (AR.QFORM.GROUP.CREATE (OR LOCAL.AR.INDEX.NAME AR.INDEX.DEFAULT.FILE.NAME) INDEX.WINDOW) (* ; "make main unsorted summary") (* ; "print summaries for each person") (AR.CLEANUP.DO.SUMMARIES INDEX.WINDOW SUMMARY.LOCAL.DIR) (CLOSEW INDEX.WINDOW]) (AR.GET.NUMS.FROM.TDS (LAMBDA (FILENAME) (* ; "Edited 20-Feb-87 11:36 by jds") (* ;; "Gather the list of ARs that have changed from the %"Tool Driver Script%" file, where AREDIT makes note of edits that people make.") (PROG ((FILE (OPENSTREAM FILENAME (QUOTE INPUT) (QUOTE OLD))) NUMBERS) (SETQ NUMBERS (while (FILEPOS " -- (" FILE NIL NIL NIL T) bind NUM? when (NUMBERP (SETQ NUM? (PROGN (READ FILE) (READ FILE)))) collect NUM?)) (CLOSEF FILE) (RETURN NUMBERS))) ) (AR.PRINT.AND.IP.FILE (LAMBDA (QFORMWINDOW FILENAME SUMMARY.LOCAL.DIR FIELDS-TO-PRINT) (* ; "Edited 1-Mar-88 17:36 by bvm") (* ;; "Take a query form and make a summary from it onto FILENAME. If SUMMARY.LOCAL.DIR is given, the file is created there and then moved to the Summaries directory, else FILENAME is written directly (default dir is still the Summaries directory).") (* ;; "FIELDS-TO-PRINT is a listing of field-name & print-length pairs for what's to appear in the summary. Defaults to whatever AR.PRINT defaults it to.") (LET* ((REMOTETXTFILE (CL:APPLY (FUNCTION PACKFILENAME.STRING) (QUOTE BODY) FILENAME (QUOTE EXTENSION) "txt" (AND (NOT (UNPACKFILENAME.STRING FILENAME (QUOTE HOST))) (BQUOTE (DIRECTORY (\, AR.SUMMARY.DIRECTORY)))))) (LOCALTXTFILE (COND (SUMMARY.LOCAL.DIR (CONCAT SUMMARY.LOCAL.DIR FILENAME ".txt")) (T (* ; "No Local directory specified, so put 'em right onto the main AR directory.") REMOTETXTFILE))) LOCALIPFILE) (printout T "Generating summary file: " FILENAME "... ") (SETQ LOCALTXTFILE (AR.MAKE.SUMMARY.FILE QFORMWINDOW LOCALTXTFILE FIELDS-TO-PRINT)) (COND (SUMMARY.LOCAL.DIR (* ; "Copy the text form of the summary to the AR directory") (printout T "copying... " (COPYFILE LOCALTXTFILE REMOTETXTFILE) " "))) (printout T "Creating Interpress file... " (SETQ LOCALIPFILE (AR.MAKE.SUMMARY.FILE QFORMWINDOW (AR.OPEN.IP.STREAM (PACKFILENAME.STRING (QUOTE EXTENSION) "IP" (QUOTE VERSION) NIL (QUOTE BODY) LOCALTXTFILE)) FIELDS-TO-PRINT)) " ") (COND (SUMMARY.LOCAL.DIR (* ; "Finally, copy the IP file back to the main AR directory and delete the local copies.") (printout T "copying... " (COPYFILE LOCALIPFILE (PACKFILENAME.STRING (QUOTE EXTENSION) "IP" (QUOTE VERSION) NIL (QUOTE BODY) REMOTETXTFILE)) " ") (DELFILE LOCALTXTFILE) (DELFILE LOCALIPFILE))) (printout T "done" T))) ) (AR.QUERY.PRINT.AND.IP.FILE (LAMBDA (INDEX.WINDOW.OR.FILE QLIST SLIST FILENAME SUMMARY.LOCAL.DIR FIELDS-TO-PRINT) (* ; "Edited 29-Feb-88 19:35 by bvm") (* ;; "Query on QLIST, sorted by SLIST, and make a summary and ip file for it. If INDEX.WINDOW.OR.FILE is not a window, we'll create and close a fake window, in which case INDEX.WINDOW.OR.FILE can be the name of the index file to use.") (LET* ((INDEX.WINDOW (WINDOWP INDEX.WINDOW.OR.FILE)) (OPENED INDEX.WINDOW)) (if (NOT OPENED) then (* ; "Make a fake query window") (SETQ INDEX.WINDOW (CREATEW (CREATEREGION 660 100 350 65))) (LET ((AR.ALWAYS.CACHE.INDEX NIL)) (AR.QFORM.GROUP.CREATE (OR INDEX.WINDOW.OR.FILE AR.INDEX.DEFAULT.FILE.NAME) INDEX.WINDOW T))) (AR.QUERY INDEX.WINDOW QLIST SLIST) (AR.PRINT.AND.IP.FILE INDEX.WINDOW FILENAME SUMMARY.LOCAL.DIR FIELDS-TO-PRINT) (if (NOT OPENED) then (CLOSEW INDEX.WINDOW)))) ) ) (* ; "Special versions of CLEANUP") (DEFINEQ (AR.CLEANUP.DO.SUMMARIES [LAMBDA (INDEX.WINDOW SUMMARY.LOCAL.DIR) (* ; "Edited 1-Apr-92 16:55 by jds") (* ;; "Make various specialized summaries, then personal ones for each hacker") [LET ((SORT.ORDER (REMOVE 'Status%: AR.CLEANUP.SORT.ORDER))) (* ; "make report for Rooms") (AR.QUERY.PRINT.AND.IP.FILE INDEX.WINDOW '(AND (Status%: >= Open/Unreleased) (System%: IS Rooms)) SORT.ORDER "RoomsSummary" SUMMARY.LOCAL.DIR) (* ; "make report for Loops") (AR.QUERY.PRINT.AND.IP.FILE INDEX.WINDOW '(AND (Status%: >= Open/Unreleased) (System%: IS LOOPS)) SORT.ORDER "LoopsSummary" SUMMARY.LOCAL.DIR) (* ; "make report for Maiko") (AR.QUERY.PRINT.AND.IP.FILE INDEX.WINDOW '(AND (Status%: >= Open/Unreleased) (System%: IS Maiko)) SORT.ORDER "MaikoSummary" SUMMARY.LOCAL.DIR) (* ;  "make report for all Absolutely ARs") (AR.QUERY.PRINT.AND.IP.FILE INDEX.WINDOW '(AND (Status%: >= Open/Unreleased) (Priority%: IS Absolutely)) AR.CLEANUP.SORT.ORDER "AbsolutelySummary" SUMMARY.LOCAL.DIR) (* ;; "Report on all documentation ARs:") (AR.QUERY.PRINT.AND.IP.FILE INDEX.WINDOW '(AND (Status%: >= Open/Unreleased) (OR (System%: IS Documentation) (Subsystem%: IS Documentation) (|Problem Type:| IS Documentation))) AR.CLEANUP.SORT.ORDER "DocSummary" SUMMARY.LOCAL.DIR) (* ;; "Make a report of all open ARs:") (AR.QUERY.PRINT.AND.IP.FILE INDEX.WINDOW '(Status%: >= Open/Unreleased) SORT.ORDER "OpenSummary" SUMMARY.LOCAL.DIR) (* ;; "make report for all Fixed ARs:") [AR.QUERY.PRINT.AND.IP.FILE INDEX.WINDOW '(Status%: IS Fixed) SORT.ORDER "FixedSummary" SUMMARY.LOCAL.DIR '((Edit-Date%: 9 T) (Date%: 9 T) (System%: 13 T) (Subsystem%: 14) (Status%: 10 T) (Attn%: 13) (Subject%: 55) (Priority%: 10) (Impact%: 8) (|Problem Type:| 13] (* ;  "print summary of Fixed and Closed for Medley") (AR.QUERY.PRINT.AND.IP.FILE INDEX.WINDOW '(AND (Status%: IS Closed) (OR (Date%: >= 1-Jun-90) (Edit-Date%: >= 1-Jun-90))) '(Status%: System%: Subsystem%:) "ClosedSummary" SUMMARY.LOCAL.DIR '((Edit-Date%: 9 T) (Date%: 9 T) (System%: 13 T) (Subsystem%: 14) (Status%: 10 T) (Attn%: 13) (Subject%: 55) (Priority%: 10) (Impact%: 8) (|Problem Type:| 13] (for HACKER.NAME in AR.CLEANUP.HACKER.NAMES do (AR.QUERY.PRINT.AND.IP.FILE INDEX.WINDOW `(Attn%: HAS ,(OR (SUBSTRING HACKER.NAME 1 4) HACKER.NAME)) AR.CLEANUP.SORT.ORDER (CONCAT HACKER.NAME "Summary") SUMMARY.LOCAL.DIR]) (AR.CLEANUP.REDO.SUMMARIES (LAMBDA (INDEX.WINDOW SUMMARY.LOCAL.DIR) (* ; "Edited 24-Feb-88 19:27 by bvm") (AR.CLEANUP.DO.SUMMARIES INDEX.WINDOW) (* ; "Dunno why there's this extra random summary...") (AR.QUERY.PRINT.AND.IP.FILE INDEX.WINDOW (QUOTE (OR (AND (System%: IS Programming% Environment) (Subsystem%: IS Break% Package)) (AND (System%: IS Common% Lisp) (OR (Subsystem%: IS Debugging) (Subsystem%: IS Break% Package) (Subsystem%: IS Error% System))))) (QUOTE (Subsystem%: Status%:)) "KelleySummary" SUMMARY.LOCAL.DIR)) ) (AR.CLEANUP.NO.SUMMARIES (LAMBDA (UPDATE.FLG INDEX.LOCAL.DIR SUMMARY.FLG SUMMARY.LOCAL.DIR) (* ; "Edited 24-Feb-88 17:06 by bvm") (AR.CLEANUP UPDATE.FLG INDEX.LOCAL.DIR NIL SUMMARY.LOCAL.DIR)) ) ) (* ; "List of names to generate summaries for") (RPAQ? AR.CLEANUP.HACKER.NAMES '(Bane Gadener Masinter Mitani Osamu Porter Prolog Shimizu Sybalsky vanMelle Welch)) (RPAQ? AR.CLEANUP.SORT.ORDER '(System%: Subsystem%: Status%: Priority%: Impact%:)) (RPAQ? AR.SUMMARY.DIRECTORY "{AR:MV:Envos}Summaries>") (CL:PROCLAIM '(CL:SPECIAL AR.CLEANUP.HACKER.NAMES AR.CLEANUP.SORT.ORDER AR.SUMMARY.DIRECTORY)) (PUTPROPS ARCLEANUP COPYRIGHT ("Venue & Xerox Corporation" 1984 1985 1986 1987 1988 1989 1990 1992)) (DECLARE%: DONTCOPY (FILEMAP (NIL (1698 8805 (AR.CLEANUP 1708 . 5632) (AR.GET.NUMS.FROM.TDS 5634 . 6105) ( AR.PRINT.AND.IP.FILE 6107 . 7924) (AR.QUERY.PRINT.AND.IP.FILE 7926 . 8803)) (8850 14249 ( AR.CLEANUP.DO.SUMMARIES 8860 . 13514) (AR.CLEANUP.REDO.SUMMARIES 13516 . 14047) ( AR.CLEANUP.NO.SUMMARIES 14049 . 14247))))) STOP