[dia/neduard/add_editorconfig] !20 Add extra rules in editorconfig.
- From: Eduard <neduard src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [dia/neduard/add_editorconfig] !20 Add extra rules in editorconfig.
- Date: Thu, 31 Jan 2019 11:08:51 +0000 (UTC)
commit eae726fb085713b94a76a93cdd9f6cff8a8f3c49
Author: Eduard Nicodei <eddnicodei gmail com>
Date: Thu Jan 31 09:55:52 2019 +0000
!20 Add extra rules in editorconfig.
- root=true as per the documentation
- indent_size = 2 only for c/cpp
- max_line_length = 80 for sources
- max_line_length = 60 for meson.build.
.editorconfig | 21 +++++++++++++++++++--
1 file changed, 19 insertions(+), 2 deletions(-)
---
diff --git a/.editorconfig b/.editorconfig
index 9abed51e..db8e29cf 100644
--- a/.editorconfig
+++ b/.editorconfig
@@ -1,5 +1,22 @@
-[*.{c, h}]
+# EditorConfig is awesome:
+# https://EditorConfig.org
+root = true
+
+# Global rules (applies to all files).
+[*]
+end_of_line = lf
indent_style = space
-indent_size = 2
insert_final_newline = true
trim_trailing_whitespace = true
+indent_size = 4
+
+# Define rules for individual file names.
+[*.{py,c,h,cpp}]
+max_line_length = 80
+
+# Meson reads better with short lines.
+[meson.build]
+max_line_length = 60
+
+[*.{c,h,cpp}]
+indent_size = 2
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]