Slashdot Mirror


Open Source Contributions More Important Than Tabs Vs Spaces For Salary (opensource.com)

Jason Baker, a Red Hat data analyst, doesn't believe developers who use spaces make more money than those who use tabs. An anonymous reader quotes Baker's blog post: After reading the study one data scientist, Evelina Gabasova, performed some additional analysis and came to a slightly different conclusion, which feels a little more precise: "Environments where people use Git and contribute to open source are more associated both with higher salaries and spaces, rather than with tabs." In other words, if you're at a company where you're using version control and committing open source code upstream, you're statistically a little more likely to be a space-user and a higher wage-earner.
Even across all experience levels, contributing to open source still correlates to higher salaries, Gabasova concludes. "My theory is that when diverse people are working on open source projects together without enforced coding style, the possible formatting mess is nudging people towards using spaces simply because the code is consistent for everyone.

"This is just one of the possible theories, I didn't look to see if possibly language communities that use predominantly spaces (like Python or Ruby) are more active in open source."

19 of 164 comments (clear)

  1. Oh come on! by Frosty+Piss · · Score: 4, Funny

    Wait, there is no connection between spaces, tabs, and how much I make? But I just spent days going through all my code and replacing and reformatting with spaces. Please don't tell me I have to be worried about curly braces.

    --
    If you want news from today, you have to come back tomorrow.
    1. Re:Oh come on! by Xtifr · · Score: 3, Funny

      If it took you days to figure out how to run find(1) and expand(1) (or indent(1) if you wanted to get fancy), then maybe you don't deserve the big bucks!

      On the other hand, if you simply have so much code that it took days for your script to run, then you have my sympathy. :)

    2. Re:Oh come on! by mwvdlee · · Score: 2

      People who use spaces instead of tabs are 4 to 8 times less efficiënt.

      --
      Slashdot social media options: AIM, ICQ, Yahoo, Jabber and Mobile Text. Why no MySpace?
    3. Re: Oh come on! by prefec2 · · Score: 2

      The cool thing is in modern IDEs , you press tab, but the machine uses spaces. Also this git thingy can transform that for you automatically.

    4. Re: Oh come on! by ceoyoyo · · Score: 2

      Yeah, but when you're deleting those "tabs" you have to hit backspace four times instead of one.

      Plus your code is bigger because it's using four+ characters to encode a single tab.

  2. yay by sootman · · Score: 3

    Score one for correlation vs. causation.

    https://xkcd.com/552/

    --
    Dear Slashdot: next time you want to mess with the site, add a rich-text editor for comments.
    1. Re:yay by beelsebob · · Score: 2

      Heh, I'm amazed that no one suggested that this would be the actual causation way back then.

      Oh wait, I did... https://slashdot.org/comments....

  3. Here is my thought on spaces/tabs by El+Cubano · · Score: 4, Insightful

    Spaces -> the person who writes the code decides how its indentation looks

    Tabs -> the person who reads the code decides how the indentation looks

    Sometimes I set tabs to be 4 spaces, sometimes 8, sometimes even 2 spaces. However, if the formatting is all done with spaces I don't get that choice. I find tabs more empowering to me personally and I believe that I use them I empower those who read my code.

    1. Re:Here is my thought on spaces/tabs by Anonymous Coward · · Score: 5, Informative

      Yeah, and then you try to align something at sub-tab resolution and it's all messed up when you change the tab width.

    2. Re:Here is my thought on spaces/tabs by afxgrin · · Score: 2

      I'm forced to be a Spacer my employer's antiquated pre-compiler seems to lose it's shit when it parses a tab.

      I let my guard down one day despite being warned by a colleague on the pitfalls of tabs in our build process and spent a significant part of my day tracing some weird compiler message down to a tab used on one line.

      I really should just pop the key off my keyboard, it's not worth the hassle of ever having it again.

    3. Re:Here is my thought on spaces/tabs by Aighearach · · Score: 2

      You know, if you use a modern editor like emacs or vi you can have it do an "auto indent" on the current line when you press the tab key. There is no reason for that button to be inserting tabs when your build process has banished them. It is your fault. Do better.

    4. Re:Here is my thought on spaces/tabs by ceoyoyo · · Score: 2

      Yes, that's a feature. If you're the kind of jerk who tries to align code at sub-tab resolution then you can't, at least in whitespace sensitive languages like Python. If you want to align your pretty comments that way, go ahead and use spaces, because it doesn't make the slightest difference.

  4. Re: As a programmer for over forty years... by Zero__Kelvin · · Score: 3, Funny

    We understand tabs. That is why we don't use them. If you can't figure out why tabs are a bad idea that is an indication of your incompetence, not ours.

    --
    Guns don't kill people; Physics kills people! - John Lithgow as Dick Solomon on Third Rock From The Sun
  5. When you contribute you don't choose style. by tomxor · · Score: 2

    Unless you originated the project, the number one rule is consistency. If you do a lot of contributing to open source then you will find a lot of projects with spaces... and regardless of your preference you will stick to that style if you want your code to be merged.

    I'm a tab guy, it's just a preference... Yet all of my open source contributions to projects other than my own use spaces.

  6. Interesting article on pros/cons.. by Anonymous Coward · · Score: 2, Informative

    Read this a while back, had to go digging for it:

    https://opensourcehacker.com/2...

    P.S. The commentary is more insightful than the article itself.

    1. Re:Interesting article on pros/cons.. by JaredOfEuropa · · Score: 2

      The ARE no relevant pros and cons. It's all rubbish. That article is biased, clearly written by a guy who prefers spaces. I can find several other articles extolling the virtues of using tabs. But in the end... how often has this issue actually tripped you up? How often, for that matter, has the use of C&R style braces vs. Berkeley style actually mattered? I've done some projects where tabs, spaces, curly styles and other stuff usually locked down in style guides was freely mixed, and you know what? It. Didn't. Matter.

      Style guides should be just that: a guide.

      --
      If construction was anything like programming, an incorrectly fitted lock would bring down the entire building...
  7. Re:Higher salaries my arse by beelsebob · · Score: 2

    What are the chances you are submitting to open source and having a high salary?

    Pretty high - most (all?) of the large tech companies have started, and/or contribute heavily to massive open source projects.

    Apple - WebKit, clang, llvm, Swift, BSD, ...
    Amazon - Outlier? I don't know of any major open source contributions of Amazon.
    Alphabet - Go, WebKit, Android, map reduce, ...
    MS - vscode, WTS, Typescript, ...
    Facebook - redux, React, flow, ...

    If you're working at a large tech company, there's a pretty significant chance you're doing work on open source.

  8. Tabs are a poor approximation by Bruce+Perens · · Score: 2

    Tabs descend from the manual typewriter, where they were a poor approximation to properly-formatted columnar layouts. Unfortunately now they join several other forms of white-space (because of Unicode) which are sometimes impossible to distinguish from each other. The safest thing to do is thus to only use space for horizontal spacing. Certainly software should not distinguish white-space characters differently. I'm looking at you, "Make", and yes I've heard the story about it being too late to change because there were already 12 users.

  9. When using Emacs, the tabs/spaces argument is moot by kriston · · Score: 2

    When using Emacs, the tabs/spaces argument is moot.

    When spaces are used, Emacs handles that automatically.

    When tabs are used, Emacs also handles that automatically and elegantly.

    When both tabs and spaces are used, Emacs also handles that automatically, elegantly, and beautifully.

    The world might be a much better place if we all used Emacs.

    --

    Kriston