[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: replace-regexp, the byte-compiler, docstrings, and suggestions

From: Emanuel Berg
Subject: Re: replace-regexp, the byte-compiler, docstrings, and suggestions
Date: Fri, 17 Oct 2014 03:09:08 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)

Drew Adams <> writes:

>> (indent-rigidly (region-beginning) (region-end) 4)
>> seems to sometimes insert tabs (one tab and one
>> space in text-mode, but four spaces in message-mode
>> what I can see). If you can have it not do that
>> (insert tabs, ever) I'm happy.
> C-h v indent-tabs-mode


Now I have this to get away with tabs:

(defun untab-all ()
  (if (not (member major-mode '(makefile-gmake-mode
                                makefile-mode) )) ; exceptions
      (untabify (point-min) (point-max)) )
  nil) ; tell 'did not write buffer to disk'

(setq before-save-hook '(untab-all delete-trailing-whitespace))

Note the Makefile exceptions because what it seems they
don't reason with whitespaces instead of tabs. (Yes, a
bit surprising, like Python, only I don't remember if
that compulsory indentation stretched to include the
indentation-char(s) as well.)

Anyway I just might remove all that stuff since I
myself never include tabs and if the indentation
doesn't either, where should they come from to begin

Only with the Makefile stuff I have to invert the
current situation to instead have the Makefiles
actually keep indent-tabs-mode as t. Ha ha, and to
think some people think programming is difficult!

underground experts united

reply via email to

[Prev in Thread] Current Thread [Next in Thread]