Red Hat Bugzilla – Bug 461357
Code cleanup - tabs vs. spaces
Last modified: 2008-11-21 00:19:53 EST
Created attachment 315951 [details]
Cosmetics - replace tabs with spaces
I've spent most of the last 3 weeks on and off hacking on a PLD installer based on Anaconda. Some of these changes could be pushed upstream but it's hard for me to produce small feature patches as:
* currently git anaconda uses mixed tabs and spaces (I think we all agree that's bad practice)
* all my editors have tabs are set to be 4 characters wide (as I work on a lot of python apps that use tabs instead of spaces and it's a lot more readable this way)
* the two above result in unreadable code so my git repo uses only spaces
* the consequence is that patches would be rather dirty (ignoring whitespace changes results in some indentation changes not being included) :)
Attached is a cosmetic patch that replaces tabs with eight spaces in all .py files (I did this by hand not to replace tabs in string constants). I know this kind of patches is generally not something maintainers love but it would make it much easier to keep our cloned trees in sync with upstream (and provide clean patches).
We've discussed cleaning up the tabs vs. spaces in the code, but we have decided to not do a huge change across the code base, but rather clean up functions as we work on them. New code will be following a policy of 4-space indentation.