From 19d22cfa36d1d05455bb4cb3eaf44043b5aeaf63 Mon Sep 17 00:00:00 2001 From: XhmikosR Date: Wed, 13 Apr 2022 08:01:43 +0300 Subject: [PATCH] build: enforce LF and update .editorconfig --- .editorconfig | 13 +++++++++++-- .gitattributes | 2 ++ gruntfile.js | 1 + 3 files changed, 14 insertions(+), 2 deletions(-) create mode 100644 .gitattributes diff --git a/.editorconfig b/.editorconfig index 363db03c..9d5248e8 100644 --- a/.editorconfig +++ b/.editorconfig @@ -1,5 +1,14 @@ +# editorconfig.org + root = true -[**.js] -indent_style = space +[*] +charset = utf-8 +end_of_line = lf indent_size = 2 +indent_style = space +insert_final_newline = true +trim_trailing_whitespace = true + +[*.md] +trim_trailing_whitespace = false diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 00000000..205021e4 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,2 @@ +# Enforce Unix newlines +* text=auto eol=lf diff --git a/gruntfile.js b/gruntfile.js index b90b602a..efd5e325 100644 --- a/gruntfile.js +++ b/gruntfile.js @@ -1,6 +1,7 @@ // Do not add new tasks. Grunt is used only for building and will be replaced. module.exports = function (grunt) { grunt.loadTasks('tasks') + grunt.util.linefeed = '\n' grunt.initConfig({ pkgFile: 'package.json', build: {