From: Stefan Bund Date: Wed, 7 Dec 2016 12:06:07 +0000 (+0100) Subject: add remove-dos-eol utility X-Git-Url: http://g0dil.de/git?a=commitdiff_plain;h=29d7f5283349fca6f9ffe809b3ec003a2b666e62;p=emacs-init.git add remove-dos-eol utility --- diff --git a/setup/remove-dos-eol.el b/setup/remove-dos-eol.el new file mode 100644 index 0000000..1dc70fb --- /dev/null +++ b/setup/remove-dos-eol.el @@ -0,0 +1,9 @@ +(defun remove-dos-eol () + "Do not show ^M in files containing mixed UNIX and DOS line endings." + (interactive) + (setq buffer-display-table (make-display-table)) + (aset buffer-display-table ?\^M []) + (force-window-update (current-buffer)) + (redisplay 't)) + +(global-set-key "\C-cM" 'remove-dos-eol)