Skip to content

Commit

Permalink
Add EditorConfig configuration
Browse files Browse the repository at this point in the history
http://editorconfig.org allows you to have a single source of
configuration for *lots* of source code editors, which means that,
upon everyone using them, all noise on commits will be gone, as
everyone will be using the same formatting style for files.
  • Loading branch information
gforcada committed Dec 9, 2014
1 parent a5ec071 commit bda2643
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions docs/contribute/conventions.rst
Expand Up @@ -105,6 +105,30 @@ style on ZCML <http://docs.zope.org/zopetoolkit/codingstyle/zcml-style.html>`_
between attributes and nested elements.


EditorConfig
------------

`EditorConfig <http://editorconfig.org/>`_
provides a way to share the same configuration for all major source code editors.

You only need to install the plugin for your editor of choice,
and add the following configuration on ``~/.editorconfig``.

.. sourcecode:: ini

[*]
indent_style = space
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
charset = utf-8

[*.py]
indent_size = 4
[{*.html,*.dtml,*.pt,*.zpt,*.xml,*.zcml,*.js}]
indent_size = 2

Quoting
=======

Expand Down

0 comments on commit bda2643

Please sign in to comment.