From 54a20347c1ad636a32c67b639ab5401f1451a9a9 Mon Sep 17 00:00:00 2001 From: Koala Yeung Date: Tue, 13 Oct 2020 10:01:44 +0800 Subject: [PATCH] Specified file formats * Add .editorconfig to specify various file format in this repository. * Add .gitattributes to specify the EOL format when commit. --- .editorconfig | 20 ++++++++++++++++++++ .gitattributes | 2 ++ 2 files changed, 22 insertions(+) create mode 100644 .editorconfig create mode 100644 .gitattributes diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000..eb7e727 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,20 @@ +# top-most EditorConfig file +root = true + +# Unix-style newlines with a newline ending every file +# with UTF-8 encoding by default. +[*] +end_of_line = lf +insert_final_newline = true +charset = utf-8 + +[*.go] +indent_style = tab + +[*.{js,json}] +indent_style = space +indent_size = 2 + +[*.py] +indent_style = space +indent_size = 4 diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..3a04b94 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,2 @@ +# Force all text file to use Unix EOL +* text=auto eol=lf