Re: pygi's style

On Wed, May 26, 2010 at 11:09, Tomeu Vizoso <tomeu tomeuvizoso net> wrote:
> On Tue, May 25, 2010 at 23:12, Steve Frécinaux <code istique net> wrote:
>>> git help blame
>>>        -w
>>>            Ignore whitespace when comparing the parent's version and the
>>>            child's to find where the lines came from.
>> Please note that indent not only changes whitespace but can also add line
>> ends from place to place.
>> Maybe we'd be better off just doing a sed -e 's/\t/        /g' -e 's/\s*$//'
>> instead if the parens and bracket usage is already consistent in the code.
> The problem is that little is consistent in the code. The good news is
> that we have been following mostly two styles.
> I will see about first applying white space fixes that don't hurt git
> blame -w, then the changes that do affect it.
> If we get to a consistent state, we can add the git hook and forget
> about all this.

Done, found an astyle invocation that makes things quite a bit
prettier and only changes about 5 lines of code that cannot be ignored
with -w.

Added a pre-commit hook that requires astyle, so you will need it in
order to commit. It gets installed from (stole it from

Would be great if people could give it a try and see how it works,
also would be good to know if there's any point in having a more
strict code checker such as GNU indent.



> Regards,
> Tomeu
>> _______________________________________________
>> python-hackers-list mailing list
>> python-hackers-list gnome org

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]