]> git.eshelyaron.com Git - emacs.git/commitdiff
(compilation-start): Save compilation-directory rather than
authorChong Yidong <cyd@stupidchicken.com>
Sun, 25 Mar 2007 17:52:31 +0000 (17:52 +0000)
committerChong Yidong <cyd@stupidchicken.com>
Sun, 25 Mar 2007 17:52:31 +0000 (17:52 +0000)
default-directory as local var.
(compilation-directory): Mark as safe local var.

lisp/progmodes/compile.el

index aa77caf0670f092b1e30fc4078debde7fc10394d..62bb276feebf6bbc0111750979b04bf71facdb75 100644 (file)
@@ -391,6 +391,7 @@ be added."
                    ,(expand-file-name "compilation.txt" data-directory))
   :group 'compilation)
 
+;;;###autoload(put 'compilation-directory 'safe-local-variable 'stringp)
 (defvar compilation-directory nil
   "Directory to restore to when doing `recompile'.")
 
@@ -1041,7 +1042,7 @@ Returns the compilation buffer created."
                 highlight-regexp))
        ;; Output a mode setter, for saving and later reloading this buffer.
        (insert "-*- mode: " name-of-mode
-               "; default-directory: " (prin1-to-string default-directory)
+               "; compilation-directory: " (prin1-to-string compilation-directory)
                " -*-\n"
                (format "%s started at %s\n\n"
                        mode-name