install.scm
;;; install,scm

;;; PURPOSE
;     Copies a the listit web site into a directory of
;     your choice.

(module install mzscheme
  (provide install)
  
  (require (lib "file.ss")
           (lib "etc.ss"))
  
  (define (install dest-dir)
    (cond
      [(directory-exists? dest-dir)
       (display (format "The directory ~a already exists.\n" dest-dir))
       (display "Delete it before calling calling install.\n")]
      [else
       (display (format "Copying the web-site to ~a.\n Please wait...\n" dest-dir))
       (copy-directory/files (build-path (this-expression-source-directory) "listit") dest-dir)
       (display (format "The web-site has now been copied to ~a.\n" dest-dir))
       (display "To test it, open \"launch.scm\" in DrScheme and run it.\n")])))