(DEFINE-FILE-INFO PACKAGE "INTERLISP" READTABLE "INTERLISP" BASE 10)
(FILECREATED "27-Sep-88 22:56:49" {PHYLUM}<BURWELL>LISP>LYRIC>LOADPATCHES.;1 1961   

      changes to%:  (FNS LoadPatches)

      previous date%: " 7-Mar-88 14:24:06" |{IE:PARC:XEROX}<LISPUSERS>LYRIC>LOADPATCHES.;1|)


(* "
Copyright (c) 1985, 1988 by Xerox Corporation.  All rights reserved.
")

(PRETTYCOMPRINT LOADPATCHESCOMS)

(RPAQQ LOADPATCHESCOMS ((FNS LoadPatches)))
(DEFINEQ

(LoadPatches
(LAMBDA (directory ldflg afterDate) (* ; "Edited 27-Sep-88 22:47 by Burwell") (* ;;; "Load all compiled files from the directory") (DECLARE (GLOBALVARS *COMPILED-EXTENSIONS*)) (LET* ((FILING.ENUMERATION.DEPTH 1) (afterIDate (if afterDate then (OR (IDATE afterDate) 0) else 0)) (files (for file infiles directory collect (UNPACKFILENAME.STRING file (QUOTE NAME))))) (* ; "Remove duplications") (SETQ files (INTERSECTION files files)) (* ; "Use the compiled file if there is one") (SETQ files (for file in files collect (OR (for extension in *COMPILED-EXTENSIONS* bind filename thereis (SETQ filename (INFILEP (CONCAT directory file "." extension))) finally (RETURN filename)) (INFILEP (CONCAT directory file))))) (* ;; "We could have picked up files that existed in a subdirectory -- but they got turned into NIL in the INFILEP") (SETQ files (DREMOVE NIL files)) (* ; "Now sort the files by date") (SETQ files (for file in files collect (CONS file (GETFILEINFO file (QUOTE ICREATIONDATE))))) (SETQ files (SORT files (FUNCTION (LAMBDA (X Y) (LESSP (CDR X) (CDR Y)))))) (* ; "Finally, load the files made after the given date") (for file in files when (GREATERP (CDR file) afterIDate) do (SELECTQ ldflg (HIDDEN (* ; "Load the file, but don't put it on FILELST") (LOAD? (CAR file) T) (SETQ FILELST (DREMOVE (FILENAMEFIELD (CAR file) (QUOTE NAME)) FILELST))) (LOAD? (CAR file) ldflg))) files))
)
)
(PUTPROPS LOADPATCHES COPYRIGHT ("Xerox Corporation" 1985 1988))
(DECLARE%: DONTCOPY
  (FILEMAP (NIL (454 1873 (LoadPatches 464 . 1871)))))
STOP