diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000000..da76e2dc08 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,26 @@ +# See https://editorconfig.org + +root = true + +[*] +end_of_line = lf +charset = utf-8 +indent_size = 4 +indent_style = space +trim_trailing_whitespace = true +insert_final_newline = true + +[*.{py,pyi}] +max_line_length = 88 + +[*.{md,yaml,yml}] +indent_size = 2 + +[Makefile] +indent_style = tab + +[*.diff] +trim_trailing_whitespace = false + +[.git/*] +trim_trailing_whitespace = false diff --git a/README.md b/README.md index 2556752e6b..15f56be29e 100644 --- a/README.md +++ b/README.md @@ -494,6 +494,15 @@ If using make with pip, running `make` will ensure the development environment is up to date with the specified dependencies, useful after fetching from git and rebasing. +#### Editing the source + +Pick your favorite text editor or development environment! + +The source includes an `.editorconfig` file which enables many editors to +automatically configure themselves to produce files which meet the minimum +requirements for the project. See https://editorconfig.org for editor support; +note that some may require plugins if you wish to use this feature. + #### Passing linters and automated tests The linters and automated tests (pytest) are run in CI (GitHub Actions) when