comparison lisp/files.el @ 282:c42ec1d1cded r21-0b39

Import from CVS: tag r21-0b39
author cvs
date Mon, 13 Aug 2007 10:33:18 +0200
parents 7df0dd720c89
children 558f606b08ae
comparison
equal deleted inserted replaced
281:090b52736db2 282:c42ec1d1cded
1084 ;; than when we save the buffer, because we want 1084 ;; than when we save the buffer, because we want
1085 ;; autosaving to work. 1085 ;; autosaving to work.
1086 (setq buffer-read-only nil) 1086 (setq buffer-read-only nil)
1087 ;; XEmacs 1087 ;; XEmacs
1088 (or (file-exists-p (file-name-directory buffer-file-name)) 1088 (or (file-exists-p (file-name-directory buffer-file-name))
1089 (if (yes-or-no-p 1089 (condition-case nil
1090 (format 1090 (if (yes-or-no-p
1091 "The directory containing %s does not exist. Create? " 1091 (format
1092 (abbreviate-file-name buffer-file-name))) 1092 "\
1093 (make-directory (file-name-directory 1093 The directory containing %s does not exist. Create? "
1094 buffer-file-name) 1094 (abbreviate-file-name buffer-file-name)))
1095 t))) 1095 (make-directory (file-name-directory
1096 buffer-file-name)
1097 t))
1098 (quit
1099 (kill-buffer (current-buffer))
1100 (error "Canceled"))))
1096 nil)))) 1101 nil))))
1097 (if msg 1102 (if msg
1098 (progn 1103 (progn
1099 (message "%s" msg) 1104 (message "%s" msg)
1100 (or not-serious (sit-for 1 t))))) 1105 (or not-serious (sit-for 1 t)))))