[bind10-dev] tabs are now prohibited?
Shane Kerr
shane at isc.org
Mon Aug 17 14:05:45 UTC 2009
Jinmei,
On Sun, 2009-08-16 at 19:49 -0700, JINMEI Tatuya / 神明達哉 wrote:
> At Mon, 17 Aug 2009 01:48:54 +0000,
> Evan Hunt <each at isc.org> wrote:
>
> > > Is that an intentional change? I remember we discussed style change
> > > from 8-tab to 4-tab, but I'm afraid it's too restrictive to completely
> > > prohibit tab characters even with 4-tab.
> >
> > We discussed this at the meeting last week--the plan was to change to
> > 4-space indentation, using spaces only, not tabs.
>
> Hmm, I don't remember the using-space-only part of the discussion, and
> while I think I still prefer using tabs where applicable I guess it's
> a mere preference (I cannot come up with any practical reason for
> tabs). I was concerned about emacs inserting tabs automatically for 8
> spaces, but I found I can disable it by setting indent-tabs-mode to
> nil (why did I even think I couldn't with Emacs?). So, if others
> prefer not using tabs, I'm okay with that policy.
We did discuss this, although perhaps we didn't highlight this
particular point enough.
My concern is with this:
* Alice makes a nice file, tabs set at 8 characters, where spaces
get "compressed" to tabs.
* Bob edits the file, with his tabs set to 6 characters, so he
adds 2 extra spaces for the few lines he touches.
* Alice looks at the file again, and it's a mess.
Rob's answer to this is "use Emacs and have the editor re-indent
everything when you open a file". Not so nice when looking via a web
browser, or for those of us stuck in 1980 and still using vi. :)
However, we can also avoid this problem by forbidding use of tabs, which
I thought we agreed to.
> > (I do think it would be better if it were possible to override the
> > restriction when you have a good reason to, though. Does the precommit
> > script have any such capability?)
>
> Without modifying the script? From a quick look at the source code I
> suspect it's not possible.
Right now the script is pretty dumb, and just blindly looks for tab
characters. We can add a keyword like "BIND10_ALLOW_HARD_TABS" that
people can put in the comments if we want to. Or we can make the script
allow existing files with tabs to be updated.
Thoughts?
--
Shane
More information about the bind10-dev
mailing list