On 10/20/2016 02:38 AM, Wouter Verhelst wrote: > On Wed, Oct 19, 2016 at 05:07:11PM -0500, Eric Blake wrote: >> I noticed that nbd source code prefers the use of hard tab instead of >> spaces for indentation, and emacs does not play nicely with that by >> default. Does anyone have the proper emacs configuration for easier >> editing of this codebase that doesn't butcher existing style? And if so, >> can we add it within a .dir-locals.el file to make it apply to fresh git >> checkouts? > > I don't insist on tabs. If you prefer spaces, we can move to spaces; I'll just > have to add "set expandtab" to my .vimrc ;-) I don't mind tabs, and I'd rather not reindent the whole code-base. But what I do mind is that emacs defaults to thinking that code should use 2-space indents (whether it uses tabs or spaces for every 8 spaces is a separate setting); while nbd uses 8-space indents (with 8 spaces written as tab). Emacs can be taught to live with that, and I was just seeing if someone knew the magic incantation to do so; and if so, if we can then automate it by adding a file to the repository. -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
Attachment:
signature.asc
Description: OpenPGP digital signature