diff options
author | Richard M. Stallman <rms@gnu.org> | 1995-06-16 01:25:53 +0000 |
---|---|---|
committer | Richard M. Stallman <rms@gnu.org> | 1995-06-16 01:25:53 +0000 |
commit | d99671d7b9265ec3719af578f5578d5bae994699 (patch) | |
tree | be667f284969407fedb5f18f12cd2c5ec564fe3a /lisp/w32-fns.el | |
parent | 35d6dd87feea8ef2057910098aadae6f5316fdee (diff) | |
download | emacs-d99671d7b9265ec3719af578f5578d5bae994699.tar.gz |
(grep-null-device): Set to "NUL".
(grep-regexp-alist): Match entries with drive letters.
(save-to-unix-hook,revert-from-unix-hook): Defined.
(using-unix-filesystems): Defined.
(window-frame): Unaliased.
Diffstat (limited to 'lisp/w32-fns.el')
-rw-r--r-- | lisp/w32-fns.el | 31 |
1 files changed, 30 insertions, 1 deletions
diff --git a/lisp/w32-fns.el b/lisp/w32-fns.el index 3ce4aedcc60..7790d5178f8 100644 --- a/lisp/w32-fns.el +++ b/lisp/w32-fns.el @@ -63,6 +63,13 @@ ;; Use ";" instead of ":" as a path separator (from files.el). (setq path-separator ";") +;; Set the null device (for compile.el). +(setq grep-null-device "NUL") + +;; Set the grep regexp to match entries with drive letters. +(setq grep-regexp-alist + '(("^\\(\\([a-zA-Z]:\\)?[^:( \t\n]+\\)[:( \t]+\\([0-9]+\\)[:) \t]" 1 3))) + ;; Taken from dos-fn.el ... don't want all that's in the file, maybe ;; separate it out someday. @@ -123,8 +130,30 @@ against the file name, and TYPE is nil for text, t for binary.") ;;; To set the default file type on new files. (add-hook 'find-file-not-found-hooks 'find-file-not-found-set-buffer-file-type) +;;; For using attached Unix filesystems. +(defun save-to-unix-hook () + (save-excursion + (setq buffer-file-type t)) + nil) + +(defun revert-from-unix-hook () + (save-excursion + (setq buffer-file-type (find-buffer-file-type (buffer-file-name)))) + nil) + +;; Really should provide this capability at the drive letter granularity. +(defun using-unix-filesystems (flag) + (if flag + (progn + (add-hook 'write-file-hooks 'save-to-unix-hook) + (add-hook 'write-contents-hooks 'save-to-unix-hook) + (add-hook 'after-save-hook 'revert-from-unix-hook)) + (progn + (remove-hook 'write-file-hooks 'save-to-unix-hook) + (remove-hook 'write-contents-hooks 'save-to-unix-hook) + (remove-hook 'after-save-hook 'revert-from-unix-hook)))) + ;;; Fix interface to (X-specific) mouse.el -(defalias 'window-frame 'ignore) (defalias 'x-set-selection 'ignore) (fset 'x-get-selection '(lambda (&rest rest) "")) (fmakunbound 'font-menu-add-default) |