aboutsummaryrefslogtreecommitdiffstats
path: root/lisp
diff options
context:
space:
mode:
authorEli Zaretskii1998-05-21 14:26:10 +0000
committerEli Zaretskii1998-05-21 14:26:10 +0000
commit3096684711648eea84af4061bf769f0692af8f60 (patch)
tree03da2f53e521cf70151a2c1cc8935c108c285682 /lisp
parent4dbbd6a16697c5d30ae3aaf43432e9e437fa82ea (diff)
downloademacs-3096684711648eea84af4061bf769f0692af8f60.tar.gz
emacs-3096684711648eea84af4061bf769f0692af8f60.zip
(file-name-invalid-regexp): New variable, moved here from arc-mode.el
Diffstat (limited to 'lisp')
-rw-r--r--lisp/files.el12
1 files changed, 12 insertions, 0 deletions
diff --git a/lisp/files.el b/lisp/files.el
index d0ecd6c2922..7d1ffa81235 100644
--- a/lisp/files.el
+++ b/lisp/files.el
@@ -170,6 +170,18 @@ If the buffer is visiting a new file, the value is nil.")
170(defvar buffer-file-numbers-unique (not (memq system-type '(windows-nt))) 170(defvar buffer-file-numbers-unique (not (memq system-type '(windows-nt)))
171 "Non-nil means that buffer-file-number uniquely identifies files.") 171 "Non-nil means that buffer-file-number uniquely identifies files.")
172 172
173(defvar file-name-invalid-regexp
174 (cond ((and (eq system-type 'ms-dos) (not (msdos-long-file-names)))
175 (concat "\\(^\\([A-z]:\\)?/?.*:\\)\\|" ; colon except after drive
176 "[+, ;=|<>\"?*]\\|\\[\\|\\]\\|" ; invalid characters
177 "\\(/\\.\\.?[^/]\\)\\|" ; leading dots
178 "\\(/[^/.]+\\.[^/.]*\\.\\)")) ; more than a single dot
179 ((memq system-type '(ms-dos windows-nt))
180 (concat "\\(^\\([A-z]:\\)?/?.*:\\)\\|" ; colon except after drive
181 "[|<>\"?*]")) ; invalid characters
182 (t "[\000]"))
183 "Regexp recognizing file names which aren't allowed by the filesystem.")
184
173(defcustom file-precious-flag nil 185(defcustom file-precious-flag nil
174 "*Non-nil means protect against I/O errors while saving files. 186 "*Non-nil means protect against I/O errors while saving files.
175Some modes set this non-nil in particular buffers. 187Some modes set this non-nil in particular buffers.