unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: pjb@informatimago.com (Pascal J. Bourguignon)
To: help-gnu-emacs@gnu.org
Subject: Re: underline-line
Date: Sat, 26 Dec 2009 00:52:25 +0100	[thread overview]
Message-ID: <87637uobly.fsf@hubble.informatimago.com> (raw)
In-Reply-To: 87tyveirfi.fsf@lion.rapttech.com.au

Tim X <timx@nospam.dev.null> writes:

> Cecil Westerhof <Cecil@decebal.nl> writes:
>
>> pjb@informatimago.com (Pascal J. Bourguignon) writes:
>>
>>> Cecil Westerhof <Cecil@decebal.nl> writes:
>>> There should be no problem with tabs, because there should be not tab
>>> in text files.
>>
>> I do not use them, but I know that other people do. Better to describe
>> the consequences then, so that people are not taken by surprise.
>>
>>
>>> The only place where prefix tabs are allowed, for historical reasons
>>> is in Makefile.  
>>
>> I know a lot of people who use it for indenting and it is used for
>> 'tables'. But maybe I should give a warning when tabs are found in the
>> text.
>> But maybe I should document the function works with 'clean' text files.
>
> I personally don't think tabs are a problem What is a problem is when
> you get source files that have a mixture of tabs and spaces where they
> are not used consistently. 
>
> Using tabs for indent can actuallly be very useful. If I'm working with
> a team and we all have different preferences for how large our code
> indents are, rather than forcing a standard indent size on all team
> members, we can just use tabs and each member can set the tab width to
> their preferred indent size i.e. 2 spaces, 4 spaces, 8 spaces etc. 

C-x h C-M-\

I'd even put the equivalent in find-file-hook...
(and possibly the same in save-file-hook with the project parameters).



> The problem is when you have some people indenting using spaces and some
> using tabs. Then all the indenting gets screwed up. 
>
> I don't have an issue with tabs in Makefiles. The emacs Makefile mode
> can show tabs/spaces, so its easy to see when something is wrong/missing
> a leading tab. 
>
> I doubt we can change make effectively. There are millions of lines of
> makefile code with tabs out there (I was told there are more lines of
> Makefile code out there than Ruby). Much of this code is in projects
> that are unlikely to have the inclination or resoruces to want to modify
>  their Makefiles to remove the tabs. Changing make to handle just
>  generic whitespace (i.e. space or tab) would be possible, but it won't
>  remove tabs from the equation. We are pretty much stuck with them for
>  the time being.

Makefile:2:warning TAB used instead of space
Makefile:3:warning TAB used instead of space
Makefile:4:warning TAB used instead of space
Makefile:6:warning TAB used instead of space
Makefile:7:warning TAB used instead of space
...


-- 
__Pascal Bourguignon__                     http://www.informatimago.com/


  reply	other threads:[~2009-12-25 23:52 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-12-24 11:06 underline-line Cecil Westerhof
2009-12-24 11:23 ` underline-line Cecil Westerhof
2009-12-24 12:21   ` underline-line Reiner Steib
2009-12-24 12:50     ` underline-line Cecil Westerhof
2009-12-24 15:32 ` underline-line Pascal J. Bourguignon
2009-12-25  5:59   ` underline-line tomas
2009-12-25  6:33   ` underline-line Cecil Westerhof
2009-12-25 23:07     ` underline-line Tim X
2009-12-25 23:52       ` Pascal J. Bourguignon [this message]
2009-12-26  7:03         ` underline-line Tim X
2009-12-26  9:21       ` underline-line Cecil Westerhof
     [not found]   ` <mailman.167.1261721014.18930.help-gnu-emacs@gnu.org>
2009-12-25 22:57     ` underline-line Tim X

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87637uobly.fsf@hubble.informatimago.com \
    --to=pjb@informatimago.com \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).