? site-init.lisp
? site-init.patch
Index: swank-loader.lisp
===================================================================
RCS file: /project/slime/cvsroot//slime/swank-loader.lisp,v
retrieving revision 1.37
diff -u -r1.37 swank-loader.lisp
--- swank-loader.lisp	24 Feb 2005 18:10:42 -0000	1.37
+++ swank-loader.lisp	1 Mar 2005 23:05:27 -0000
@@ -85,12 +85,6 @@
               (load source-pathname))
             ))))))
 
-(defun user-init-file ()
-  "Return the name of the user init file or nil."
-  (probe-file (merge-pathnames (user-homedir-pathname)
-                               (make-pathname :name ".swank" :type "lisp"))))
-
-       
 (compile-files-if-needed-serially
   (append (list (make-swank-pathname "swank-backend"))
           *sysdep-pathnames* 
@@ -98,5 +92,18 @@
 
 (funcall (intern (string :warn-unimplemented-interfaces) :swank-backend))
 
-(when (user-init-file)
-  (load (user-init-file)))
+(defun load-user-init-file ()
+  "Load the user init file, return NIL if it does not exist."
+  (load (merge-pathnames (user-homedir-pathname)
+                         (make-pathname :name ".swank" :type "lisp"))
+        :if-does-not-exist nil))
+(export 'load-user-init-file)
+
+(defun load-site-init-file ()
+  (load (make-pathname :name "site-init" :type "lisp"
+                       :defaults *load-truename*)
+        :if-does-not-exist nil))
+
+(or (load-site-init-file)
+    (load-user-init-file))
+
