Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding .editorconfig to preserve current whitespace styling. #31

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

fslds
Copy link

@fslds fslds commented May 4, 2021

Hello,

looking at your plea for minimal Pull Requests, I decided to add a PR for a EditorConfig first before considering other Pull Requests.
In short: the .editorconfig will enforce whitespace styling for this project in a multitude of editors/IDEs, inlcuding the Github online editor natively and vscode and vim via plugins. You can check out https://editorconfig.org/ for all details.
As you indicated that there were previous pull requests - in this project or another - that had issues with styling changes, this should alleviate some of those pains in the future.
The PR is also atomic/non-invasive: no code is changed, so there is also no need for a new release.

I know this PR may sound like an advertisement for .editorconfig, but I am in no way affiliated with that project. I am only a (happy) user. The inclusion of the file should only have positive impact, if any.
Feel free to edit the config file further to the project's preferences.

# EditorConfig is awesome: https://EditorConfig.org

# Not the top-most EditorConfig file, only contains settings for this project.
root = false

# Unix-style newlines for all files
[*]
end_of_line = lf

# Set default charset
[*.{py,md,cfg,yml,gitignore}]
charset = utf-8

# Style for Python
[*.py]
indent_style = space
indent_size = 4
insert_final_newline = true

# Style for YAML
[*.{yml,yaml}]
indent_style = space
indent_size = 2
insert_final_newline = true

@mherrmann
Copy link
Owner

Hi! I appreciate the PR and that you took the time to read through my plea. While you rightly say that your change only adds something, does not break anything, nor does it add any dependencies, it does fall under the category of "new tool". As I write in my plea, I do not like to introduce new tools unless absolutely necessary. It isn't necessary here. I get few PRs to this library. And if someone doesn't respect the whitespace, it takes me 1 minute to tell them and it takes them 2 minutes to fix it. On the other hand, by adding .editorconfig to the repo, every single person who sees the repo will see this file, and will spend at least a little mental capacity thinking about what it does. Most won't know what it is and will be confused. While I have heard of .editorconfig files before, I know little about them and have no desire to have to learn about their details, especially because they don't solve a big enough pain point here. I hope this is understandable. And thank you again for the PR. I do appreciate that we're working together to make software better.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants