qemu-trivial
[Top][All Lists]
Advanced

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

Re: [Qemu-trivial] [Qemu-devel] [PATCH] Add .dir-locals.el file to confi


From: Daniel P. Berrange
Subject: Re: [Qemu-trivial] [Qemu-devel] [PATCH] Add .dir-locals.el file to configure emacs coding style
Date: Thu, 4 Jun 2015 14:30:35 +0100
User-agent: Mutt/1.5.23 (2014-03-12)

On Wed, Jun 03, 2015 at 09:47:24AM +0200, Markus Armbruster wrote:
> "Daniel P. Berrange" <address@hidden> writes:
> 
> > The default emacs setup indents by 2 spaces and uses tabs
> > which is counter to the QEMU coding style rules. Adding a
> > .dir-locals.el file in the top level of the GIT repo will
> > inform emacs about the QEMU coding style, and so assist
> > contributors in avoiding common style mistakes before
> > they submit patches.
> 
> Yes, please!
> 
> > Signed-off-by: Daniel P. Berrange <address@hidden>
> > ---
> >  .dir-locals.el | 8 ++++++++
> >  1 file changed, 8 insertions(+)
> >  create mode 100644 .dir-locals.el
> >
> > diff --git a/.dir-locals.el b/.dir-locals.el
> > new file mode 100644
> > index 0000000..ddb2fae
> > --- /dev/null
> > +++ b/.dir-locals.el
> > @@ -0,0 +1,8 @@
> > +(
> > + (c-mode . (
> > +            (c-file-style . "K&R")
> > +            (indent-tabs-mode . nil)
> > +            (c-indent-level . 4)
> > +            (c-basic-offset . 4)
> > +            ))
> > +)

[snip]

> Does the following .dir-locals.el work for you equally well?
> 
> ((c-mode . ((c-file-style . "stroustrup")
>             (indent-tabs-mode . nil))))

Yes, that is fine too.

Regards,
Daniel
-- 
|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|



reply via email to

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