News for hackers. Stuff that matters.
Re:Lans.py: capture usernames, passwords, messages and injec... by nilliams on Saturday November 09, 2013 @08:02AM (#6701516)
I agree with you for code samples in READMEs, but for actual code allow people to respectfully disagree [1].

The benefit of tabs is that you can open it in your editor and set you editor to view tabs at whatever your spacing preference (2 or 4 spaces).

That github doesn't let you specify the tab-sizing you wish to view the code at is no fault of the author's (it would be a nice feature for github to add).

Please don't throw PEP8 at me :)

[1] http://lea.verou.me/2012/01/why-tabs-are-clearly-superior/

Re:Lans.py: capture usernames, passwords, messages and injec... by smnrchrds on Saturday November 09, 2013 @10:55AM (#6701933)
Why not? It's a convention almost everyone has agreed upon. More than 95% of python code out there uses spaces[1]. The new PEP-8 prefers spaces over tabs. I have configured my text editor to put 4 spaces when I press the tab key and auto-indent with 4 spaces as well. Now, if I want to contribute to a project which uses tabs instead of spaces or use such a project in my own code, I have to change my text editor preferences every time I open those files or fork the project and convert tabs to spaces.

Tabs may have some advantages over spaces, but uniformity is far more important.

[1] http://sideeffect.kr/popularconvention/#python

Re:Lans.py: capture usernames, passwords, messages and injec... by free652 on Saturday November 09, 2013 @10:58AM (#6701945)
Spaces look uniformed everywhere. Configuring every tool to use tabs with the right size is just crazy:

* SVN diff tools

* Web SVN webbrowsers

* Vi

* Eclipse

* Chrome