diff options
author | Andrew Innes <andrewi@gnu.org> | 1999-03-25 22:49:36 +0000 |
---|---|---|
committer | Andrew Innes <andrewi@gnu.org> | 1999-03-25 22:49:36 +0000 |
commit | 07183237bd05c98615c16e0195305fbb4b966869 (patch) | |
tree | 037bff6a7c919bfb0d5bc766958437ee988c3b46 /lisp/w32-fns.el | |
parent | f356f4b2b5f40e84ff75c59a67b0886e9dc11b7e (diff) | |
download | emacs-07183237bd05c98615c16e0195305fbb4b966869.tar.gz |
(set-default-process-coding-system): Copied from
dos-w32.el, but modified to use Unix line endings for process
input, and to add a suitable entry to process-coding-system-alist
for DOS shells.
Diffstat (limited to 'lisp/w32-fns.el')
-rw-r--r-- | lisp/w32-fns.el | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/lisp/w32-fns.el b/lisp/w32-fns.el index 33db6c011d5..1e12f177f87 100644 --- a/lisp/w32-fns.el +++ b/lisp/w32-fns.el @@ -137,6 +137,26 @@ You should set this to t when using a non-system shell.\n\n")))) (add-hook 'after-init-hook 'w32-check-shell-configuration) +;;; Override setting chosen at startup. +(defun set-default-process-coding-system () + ;; Most programs on Windows will accept Unix line endings on input + ;; (and some programs ported from Unix require it) but most will + ;; produce DOS line endings on output. + (setq default-process-coding-system + (if default-enable-multibyte-characters + '(undecided-dos . undecided-unix) + '(raw-text-dos . raw-text-unix))) + (or (w32-using-nt) + ;; On Windows 9x, make cmdproxy default to using DOS line endings + ;; for input, because command.com requires this. + (setq process-coding-system-alist + `(("[cC][mM][dD][pP][rR][oO][xX][yY]" + . ,(if default-enable-multibyte-characters + '(undecided-dos . undecided-dos) + '(raw-text-dos . raw-text-dos))))))) + +(add-hook 'before-init-hook 'set-default-process-coding-system) + ;;; Basic support functions for managing Emacs' locale setting |