From 1933a494e7f79fdb2f68fc1ed931bece5c75eff3 Mon Sep 17 00:00:00 2001 From: shouzy <82171453+realshouzy@users.noreply.github.com> Date: Tue, 29 Aug 2023 16:12:15 +0200 Subject: [PATCH 1/4] Add code style guideline of max 79 columns --- CONTRIBUTING.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index b858bc8cc..ebf19c428 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -17,3 +17,5 @@ Any kind of contribution is welcome; nothing is "off limits". However, for those This repo ([jgonggrijp/pip-review](https://github.com/jgonggrijp/pip-review)) uses [gitflow](https://github.com/nvie/gitflow). Please submit pull requests to the `develop` branch. The Python files use 4-space soft tabs. The other files use 2-space soft tabs. + +Please ensure that lines of code do not exceed a **maximum length of 79 characters** to maintain code readability and consistency throughout the project. From fad631659090cb8c66a7aee39223f014b69e7104 Mon Sep 17 00:00:00 2001 From: shouzy <82171453+realshouzy@users.noreply.github.com> Date: Wed, 30 Aug 2023 12:52:02 +0200 Subject: [PATCH 2/4] Add ``.editorconfig`` --- .editorconfig | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 .editorconfig diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 000000000..83ee8c9f5 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,13 @@ +# https://editorconfig.org/ +root = true + +[*] +charset = utf-8 +indent_style = space +indent_size = 2 +trim_trailing_whitespace = true +end_of_line = crlf +insert_final_newline = true + +[*.py] +indent_size = 4 From c44a9d76d8d49cd1f57b80d19f7c2d25f27cd2ea Mon Sep 17 00:00:00 2001 From: shouzy <82171453+realshouzy@users.noreply.github.com> Date: Wed, 30 Aug 2023 13:38:38 +0200 Subject: [PATCH 3/4] Refer to ``.editorconfig`` in ``CONTRIBUTING.md`` --- CONTRIBUTING.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index ebf19c428..d3c534ff7 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -16,6 +16,6 @@ Any kind of contribution is welcome; nothing is "off limits". However, for those This repo ([jgonggrijp/pip-review](https://github.com/jgonggrijp/pip-review)) uses [gitflow](https://github.com/nvie/gitflow). Please submit pull requests to the `develop` branch. -The Python files use 4-space soft tabs. The other files use 2-space soft tabs. +To maintain consistent coding style and formatting across the project, an [``EditorConfig`` file](/.editorconfig) has been set up, in order to guarantee that all contributors use the same settings for indentation, character encoding, line endings etc. -Please ensure that lines of code do not exceed a **maximum length of 79 characters** to maintain code readability and consistency throughout the project. +Additionally, please ensure that lines of code do not exceed a **maximum length of 79 characters** to further enhance readability and consistency of the project. From 472e40c036d1ba13c2c71c5bb162de0ccf16860a Mon Sep 17 00:00:00 2001 From: shouzy <82171453+realshouzy@users.noreply.github.com> Date: Wed, 30 Aug 2023 18:04:21 +0200 Subject: [PATCH 4/4] Change ``end_of_line`` to ``lf`` --- .editorconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.editorconfig b/.editorconfig index 83ee8c9f5..0888e7dae 100644 --- a/.editorconfig +++ b/.editorconfig @@ -6,7 +6,7 @@ charset = utf-8 indent_style = space indent_size = 2 trim_trailing_whitespace = true -end_of_line = crlf +end_of_line = lf insert_final_newline = true [*.py]