daffodil-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Steve Lawrence <slawre...@apache.org>
Subject Re: tabs vs. spaces
Date Thu, 06 Sep 2018 13:38:00 GMT
Generally, I'm not a fan of fixing tabs vs spaces errors since it can
make it a little more difficult to view the real history of changes.
Though, it's a bit less of an issue if all the changes are done in a
single commit with no other functional changes. We could run xmllint or
something on our TDML/XML files to fix those up. Not sure if something
exists for scala, but scalastyle [1] can at least find any errors.

Additionally, if we do this we, should enable the scalastyle SBT plugin
to check every pull request and fail TravisCI if bad styles sneak back
in. I can't find an sbt plugin that can validate XML formats, but
writing something that checks for tabs vs spaces probably wouldn't be
too much effort to create. Checking for things like unix vs windows line
endings would also be beneficial.

- Steve

[1] http://www.scalastyle.org


On 09/05/2018 04:19 PM, Mike Beckerle wrote:
> I may be as guilty as others here or more, but somehow our spaces vs. tabs convention
which uses 2 spaces for indenting in our code base, has gotten modified and lots of files
are showing tabs now.
> 
> 
> Especially for XML and XSD files, less so, but true for some scala and java files.
> 
> 
> Do we have a tool that fixes this for the whole tree we can just run?
> 


Mime
View raw message