[geos-devel] Breeding .editorconfig is bad
Sandro Santilli
strk at kbt.io
Fri Apr 7 04:35:03 PDT 2017
On Fri, Apr 07, 2017 at 01:04:00PM +0200, Mateusz Loskot wrote:
> Often, single file contains bits in styles and such scoped .editorconfig
> will lead to commits mixing actual (logic/behaviour) code change
> with code formatting changes. Unacceptable!
I agree it is unacceptable to mix logic and style changes in
the same commit.
Also and I think we should minimize style changes as much as possible,
which was the rationale for my adding per-directory .editorconfig.
> See the problem in action here:
> https://github.com/OSGeo/geos/pull/81/files
Could you briefly explain the problem we're seeing there ?
Is it the removal of trailing blank spaces ?
The way I've been addressing those cases has been first committing
removal of trailing blank spaces and then committing a separate
funtional change.
> My call, again, is to stop it and get rid of any spaces/indentation settings
> in .editorconfig for as long as we don't get the code reformatted into
> desired style.
> Alternatively, please, make your editors ignore .editorconfig completely
> and manually align with coding style as presented in actual file being edited.
> That's what I'm going to do.
If the problem is the one I described above there's no "pre-existing
coding style" to be preserved. It's just that someone added too many
blanks at the end of lines.
Note that `git diff --check` can do the trailing blanks check for you
before it's committed.
Please do not ignore .editorconfig as it's aimed to *reducing* the
proliferation of code styles. I've run a check under src/ and include/
some days ago and found that only a single file is not using tabs
(namely the CLocalizer class files introduced by Sean Gillies in 2008)
--strk;
More information about the geos-devel
mailing list