diff --git a/template/.editorconfig b/template/.editorconfig new file mode 100644 index 00000000..46ca6361 --- /dev/null +++ b/template/.editorconfig @@ -0,0 +1,32 @@ + +root = true + +[*.md] +charset = utf-8 +end_of_line = lf +insert_final_newline = true +trim_trailing_whitespace = true + +[*.py] +charset = utf-8 +end_of_line = lf +insert_final_newline = true +trim_trailing_whitespace = true +indent_style = space +indent_size = 4 +max_line_length = 88 + +[*.{yml,yaml,md,css,html,js,jsx,ts,tsx,json}] +indent_style = space +indent_size = 2 + +[Makefile] +indent_style = tab + +[*.sh] +end_of_line = lf +trim_trailing_whitespace = true + +[*.bat] +end_of_line = crlf +trim_trailing_whitespace = false diff --git a/template/.gitattributes b/template/.gitattributes new file mode 100644 index 00000000..0273e01d --- /dev/null +++ b/template/.gitattributes @@ -0,0 +1,28 @@ +# Auto detect text files and normalize line endings +* text=auto + +# Force LF for specific text files +*.py text eol=lf +*.sh text eol=lf +*.yml text eol=lf +*.yaml text eol=lf +*.md text eol=lf +*.txt text eol=lf +*.json text eol=lf +Dockerfile text eol=lf + +# Windows scripts keep CRLF +*.ps1 text eol=crlf +*.bat text eol=crlf + +# Binary files +*.png binary +*.jpg binary +*.jpeg binary +*.gif binary +*.ico binary +*.zip binary +*.gz binary + +# Ensure shell scripts keep LF and executable permission +*.sh eol=lf