summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2018-10-26 05:22:09 (GMT)
committerJunio C Hamano <gitster@pobox.com>2018-10-26 05:22:09 (GMT)
commit778bb5eaaac8f12406e6c56751886114c6a4ef4d (patch)
treec1567302c03f8dd14cffc4af11939e8da2b143ef
parentf76617666331a6041e001f64ba597ba7abc1ffa8 (diff)
parentb548d698a0e42d28614acb6a0792d7cfbe7ddef4 (diff)
downloadgit-778bb5eaaac8f12406e6c56751886114c6a4ef4d.zip
git-778bb5eaaac8f12406e6c56751886114c6a4ef4d.tar.gz
git-778bb5eaaac8f12406e6c56751886114c6a4ef4d.tar.bz2
Merge branch 'bc/editorconfig'
To help developers, an EditorConfig file that attempts to follow the project convention has been added. * bc/editorconfig: editorconfig: indicate settings should be kept in sync editorconfig: provide editor settings for Git developers
-rw-r--r--.clang-format2
-rw-r--r--.editorconfig16
2 files changed, 18 insertions, 0 deletions
diff --git a/.clang-format b/.clang-format
index 12a89f9..de1c8b5 100644
--- a/.clang-format
+++ b/.clang-format
@@ -6,6 +6,8 @@
# Use tabs whenever we need to fill whitespace that spans at least from one tab
# stop to the next one.
+#
+# These settings are mirrored in .editorconfig. Keep them in sync.
UseTab: Always
TabWidth: 8
IndentWidth: 8
diff --git a/.editorconfig b/.editorconfig
new file mode 100644
index 0000000..42cdc4b
--- /dev/null
+++ b/.editorconfig
@@ -0,0 +1,16 @@
+[*]
+charset = utf-8
+insert_final_newline = true
+
+# The settings for C (*.c and *.h) files are mirrored in .clang-format. Keep
+# them in sync.
+[*.{c,h,sh,perl,pl,pm}]
+indent_style = tab
+tab_width = 8
+
+[*.py]
+indent_style = space
+indent_size = 4
+
+[COMMIT_EDITMSG]
+max_line_length = 72