home *** CD-ROM | disk | FTP | other *** search
/ InfoMagic Source Code 1993 July / THE_SOURCE_CODE_CD_ROM.iso / languages / elisp / packages / HyperActiveFTP / active-hyper.Install.el < prev    next >
Encoding:
Text File  |  1992-12-11  |  4.2 KB  |  141 lines

  1. ;;
  2. ;; hyperbole and ange-ftp must be loaded for this to work
  3. ;; just type M-x eval-current-buffer and we're off
  4. ;;
  5.  
  6. (setq max-lisp-eval-depth 2000)
  7. (setq max-specpdl-size 2000)
  8.  
  9. (setq active-hyper-manifest
  10.       '(
  11.     ".hypb" ".dired"
  12.     "active-hyper.list.new"
  13.     "README.HyperActiveFTP" "active-hyper.menu.install"
  14.     "active-hyper.menu.update.big.list"
  15.     "active-hyper.Admin.el" "active-hyper.Changelog" 
  16.     "active-hyper.Install.el" "active-hyper.Makefile" 
  17.     "active-hyper.credits"
  18.     "active-hyper.documentation" "active-hyper.el"
  19.     "active-hyper.menu.main.otl" "active-hyper.menu.install"
  20.     "data.bioftp.unibas.ch" "data.biological.scientists"
  21.     "data.j" "data.kanji" "data.math.abstracts.database"
  22.     "data.mobal" "data.netlib" "data.object.oriented.parallel"
  23.     "data.paragon" "data.psfig" "data.symbmath" "data.txl"
  24.     "data.usenet"
  25.     "active-hyper.to.do"))
  26.  
  27. (setq ah-for-remote-install
  28.       '(
  29.     ".hypb" ".dired"
  30.     "active-hyper.list.new"
  31.     "README.HyperActiveFTP" "active-hyper.menu.install"
  32.     "active-hyper.menu.update.big.list"
  33.     "active-hyper.Admin.el" 
  34.     "active-hyper.Changelog" "active-hyper.Install.el"
  35.     "active-hyper.Makefile" "active-hyper.credits"
  36.     "active-hyper.documentation" "active-hyper.el"
  37.     "active-hyper.list.big.otl" 
  38.     "active-hyper.main.menu" "active-hyper.to.do"
  39.     "data.bioftp.unibas.ch" "data.biological.scientists"
  40.     "data.j" "data.kanji" "data.math.abstracts.database"
  41.     "data.mobal" "data.netlib" "data.object.oriented.parallel"
  42.     "data.paragon" "data.psfig" "data.symbmath" "data.txl"
  43.     "data.usenet"
  44. ))
  45.  
  46. (setq active-hyper-remote-dumpster "/anonymous@archive.cis.ohio-state.edu:/pub/gnu/emacs/elisp-archive/packages/HyperActiveFTP/")
  47. ;(setq active-hyper-remote-dumpster "/brannon@nic.funet.fi:/pub/gnu/emacs/elisp/HyperActive/")
  48.  
  49. ;;; ^^^--- dont forget the ENDING SLASH
  50.  
  51. ;;; Where you want HyperActive FTP installed. 
  52. ;;; Two Necessaries:
  53.  
  54. ;;; 1  DO NOT PLACE THIS BELOW A HYPERBOLE DIRECTORY. If you do, then when
  55. ;;; you wipe your current hyperbole directory to dowload a new version of
  56. ;;; hyperbole, you may wipe out HyperActive FTP also
  57. ;;; 2  Insure that the pathname ENDS WITH A SLASH.
  58. (setq ah-install-directory "~/emacs/active-hyper/")
  59.  
  60.  
  61. (defun active-hyper:local-install ()
  62.   (interactive)
  63.   (mapcar 'copy-from active-hyper-manifest)   ; copy over the basic files
  64.  
  65.   ;; add in the load of my elisp source code
  66.   (find-file (concat ah-install-directory "active-hyper.requirements.el"))
  67.   (erase-buffer)
  68.   (goto-char (point-min))
  69.   (eval-current-buffer)
  70.   (setq aha 
  71.     (concat
  72.      "(setq ah-install-directory \"" ah-install-directory "\")"))
  73.   (setq ahb
  74.     (concat
  75.      "(setq load-path (cons \"" ah-install-directory "\""
  76.      " load-path))"))
  77.   (setq ahc "(require 'ange-ftp)")
  78.   (setq ahd 
  79.     (concat
  80.      "(load-file \""
  81.      (concat (expand-file-name ah-install-directory) "active-hyper.el")
  82.      "\")"))
  83.   (insert (concat aha ahb ahc ahd))
  84.  
  85.   (save-buffer)
  86.   (kill-buffer (current-buffer))
  87.   (message "Ok, done. Just one more step."))
  88.  
  89. (defun copy-from (M)
  90.   (copy-file (concat active-hyper-remote-dumpster M)
  91.          (concat ah-install-directory M) t))
  92.  
  93.  
  94.  
  95. ;;; quasi hyper-makefile
  96.  
  97. (defun active-hyper:update-files()
  98.   (setq active-hyper-update-files
  99.     '(
  100.       "active-hyper.list.new"
  101.       "active-hyper.list.big.otl"
  102.       ".hypb"
  103.       "active-hyper.to.do"
  104.       "active-hyper.Changelog"
  105.       "active-hyper.documentation"))
  106.   (mapcar 'copy-from active-hyper-update-files))
  107.   
  108.   
  109.  
  110. (defun remote-install ()
  111.   (interactive)
  112.   (mapcar 'copy-to ah-for-remote-install))
  113.  
  114. (defun copy-to (M)
  115.   (copy-file (concat ah-install-directory M)
  116.          (concat active-hyper-remote-dumpster M) t))
  117.  
  118.  
  119.  
  120. (defun active-hyper:change-default()
  121.   (let ((aha '())
  122.     (ret nil))
  123.     (while (eq ret nil)
  124.       (progn
  125.     (setq aha (read-from-minibuffer "Where should HyperActiveFTP be installed? " "~/emacs/active-hyper"))
  126.     (setq ret (y-or-n-p (concat "Use " aha " as installation directory? ")))))
  127.     (setq ah-install-directory aha))
  128.   (message (concat "Making directory " ah-install-directory))
  129.   (active-hyper:mkdir))
  130.  
  131. (defun active-hyper:mkdir ()
  132.       (shell-command (concat
  133.               "mkdir "
  134.               (expand-file-name ah-install-directory)))
  135.       (kill-buffer "*Shell Command Output*")
  136.       (find-file "active-hyper.menu.install")
  137.       (delete-other-windows)
  138.       (message "Directory is made... Proceed to Step Two"))
  139.   
  140.  
  141.