Sure learning Linux will most likely teach you something about the platform on which anything you write will probably be deployed but that's really marginal (IMHO).
You get things done (programming included) by getting all the roadblocks out of your way. Linux is (IMHO) a roadblock. The OP claims it teaches you researching skills by giving you problems everyday you need to find solutions for. This is true in the same way that refusing to buy food of any kind teaches self-sufficiency.
To get things done you need to get in the zone. This means eliminating distractions. Trying to figure out why copy and paste doesn't work (and it turns out that it's because you're using OpenJDK instead of the Sun JDK) very much takes you out of that zone and then wastes time to boot.
This might be more useful later on (maybe) but learning to programming? No way.
To me, the best development platform is OSX. Why? Because it's (BSD) UNIX that is a pleasure to use that (mostly) doesn't have the aforementioned problems. My only real beef is that if you're used to using a program on Linux or Windows the keyboard shortcuts will generally be different on OSX (due to following the OSX conventions).
And as much as people (myself included) like to rag on Windows (in my case: the complexity), the fact is that modern Windows (Win7) is actually a pretty pleasant experience. Some things (eg git) suck but Cygwin can ameliorate a lot of those problems.
I used to have a jokes tab on my iGoogle page, one day the joke of the day was: "If you want you computer to work, use a mac, if you want to know how you computer works, use linux, and if you don't want to know why your computer doesn't work, use windows." I thought it was funny, and it was a step in my inspiration to use Linux.
One analogy I'll make to promote learning on Linux: When I started playing guitar, any experienced player or teacher will tell you to learn on an acoustic guitar. Why? It's more challenging to make it sound good, you have to press harder on the strings, The strings are further away from the frets, you get buzz and damping if you don't use just the right form. It teaches you to over learn, then when you switch to an electric, it's easy peasy, and just sounds sooo good. I think in this case you could consider Linux to be the acoustic guitar, and Mac to be an electric. Just my two cents.
Does this make Windows the double-necked bass?
I want to see the source to the ls command? dpkg -S /bin/ls; apt-get source coreutils. I have no idea how to do that on MacOS. I want to be able to compile it? apt-get build-dep coreutils, which IIRC will install the compiler. The equivalent on MacOS involves signing up for a developer account with Apple, signing a contract that promises God knows what, and downloading a multi-gigabyte disk image. Even after installing, gcc still isn't in your PATH, and won't work properly with the platform SDK without a verbose -isysroot option. I want to make executable the file named gooba somewhere under my current directory? chmod +x $(find -name gooba). Apple's find requires an explicit `.` and maybe an explicit `-print`, I don't remember. Got performance problems on your machine? On Linux you have htop, dstat, iotop, powertop, and latencytop, none of which have MacOS equivalents as far as I know. Even plain old top has keystroke commands to switch between sorting by CPU and sorting by resident set size. As far as I can tell, doing that on MacOS requires restarting top with different command-line options. And there's no package-management system, so if you're building a server-based app, good luck installing the same versions of the same libraries on the server that you tested against in development. Or on your new dev box. And the server's probably running Linux anyway. Also, where the fuck is strace? Dtruss is a fucking piece of shit.
Admittedly XCode is a pretty nice IDE, but there are a lot of nice IDEs out there, and most of them run on Linux too. And I'd love to have dtrace on Linux.
But that aside, I'm not sure about the rest of your complaints. I just created couple new folders and 5-6 files named gooba and gooba2 and typed 'chmod +x $(find . -name gooba)' and everything worked (gooba's are executable and gooba2's are not). I don't think that extra dot is that bad and I actually like it better (it's more logical).
Also, you can install package managers such as: MacPorts or Homebrew or Fink (I prefer Homebrew). Then you can install htop, iotop, ftop, and a million other unix apps.
in 'top', if you press 'o' (order), and then 'cpu', it sorts them by CPU usage. You can even set a secondary key by pressing 'O'. And you can always "alias top='top -o cpu'" in your .aliases.
Fortunately, you can: just use a current Debian on well-supported hardware. (Until a year ago I would have recommended Ubuntu.)
> I don't think that extra dot is that bad
There are a zillion things like that in MacOS that are just that little bit harder to use, for no good reason. Requiring five extra keystrokes in `top` to get an actual list of the top processes is another example. You can come up with justifications for why the roadblocks are there, or rationalize that they're not that bad, but they really add up.it
It's like Apple's vaunted relentless focus on user experience just doesn't extend to programmers.
> Also, you can install package managers such as: MacPorts or Homebrew or Fink (I prefer Homebrew). Then you can install htop, iotop, ftop, and a million other unix apps.
If you're comparing MacPorts, Homebrew, and Fink to Debian or Ubuntu, I think you haven't used Debian or Ubuntu. I didn't realize iotop and htop had already been ported to MacOS, though. That's cool. Thanks for letting me know. Powertop, latencytop, strace, and dstat no, though, I guess?
or use wget or curl to download the source for what ever you are interested in.
First of all you need to know about apt-get. Then you need to know that ls lives in coreutils etc.
I want to see the source to the ls command? ... I have no idea how to do that on MacOS.
The rest have been addressed, but as for this:
The equivalent on MacOS involves signing up for a developer account with Apple, signing a contract that promises God knows what, and downloading a multi-gigabyte disk image.
It involves running an installer from your install disc, or, admittedly, in the case of the most recent release, downloading a multi-gigabyte disk image from the app store. You don't need a developer account if you just want to install the software.
> You don't need a developer account if you just want to install the software.
Perhaps this has changed since the last time I did it, a couple of years ago; it did then.
Really, Norvig sums this up best: "When asked "what operating system should I use, Windows, Unix, or Mac?", my answer is usually: "use whatever your friends use." "
(I use a Mac and think it's swell, but I definitely couldn't have shelled out for one as a high schooler learning to program, but could burn a weekend dual booting Linux)
I think you hit on an important point. Most people seem to be approaching this from an adult / professional perspective. I'm thinking of the bright 14-year-old kid who wants to learn about computers. He (or his parents) may not be able to afford a $2000 Macbook, but he could build his own box relatively cheaply and put a free operating system on it. Linux is democratizing that way. And he can download the source code to virtually everything running on that box. That has undoubtedly inspired a few programmers.
You cannot imagine how beneficial Linux has been in making it possible for students from countries like India to learn deeply and experiment with their systems.
Linux both forces you to figure stuff out, and enables you to, which in my case also motivated me to.
I don't know how that would have worked out had I been using OS X instead of Linux though, maybe the same since it's BSD-based. But I suspect Linux may be the only one where you can feel full ownership over your own system, and can be motivated by the knowledge that if you take the time and effort to figure it out, you can make it do anything you want to.
That personal, emotional investment I believe is the most important, rewarding, and incentivizing aspect of learning computers, computing, programming, and/or CS.
Cygwin can make life under Windows bearable, but there is a long list of confusing things people have to deal with such as the /cygdrive tree and executables always having the .exe extension. "ls" autocompleting to "ls.exe"?
When I talk to old hackers on Linux about moving to OSX, I tell them, "well, if you move, you don't have to configure your power management and display drivers and it has Emacs keybindings in all the windows!" and they get excited.
When I talk to young CS undergraduates --- all of whom have Macs, because it's not an engineering college --- I tell them, "you should learn Emacs; I know it's in a terminal, but it has all of the OSX keybindings you already started to learn!" and they get excited.
I remember the day I realized that I could have windows and play heretic all day, or install linux and tinker all day. Linux quickly won.
The biggest skill I learned from linux is to never expect things to work, and to expect the internet to fix things. My round trip time from not working to google and back to working is by far my most valuable asset as an engineer.
And still, almost every day I leave work I think "God that was awesome!". I hope that never goes away.
Oh, and so +1 for 2 hour nr epic SC battles! Except it was under wine, and man did it quake!
Advanced Bash Scripting Guide by Mendel Cooper(http://tldp.org/LDP/abs/html/) has some good scripts which I have come across for some practice but it isn't ordered. Any others ?
Get something you want to program.
Get a reference.
I am actually happy that someone told me pretty much this. It took a while until I realized how true this was. Just get something you want to do and keep that in mind when reading the reference. I know most people will start making tons of mistakes and writing really crappy code, but that's exactly what learning is about. Starting out with nothing and getting better. One learns from mistakes. Somehow people tend to forget this. Lots of people seem to be embarrassed making a mistake, causing them to don't do anything at all or not giving in that they are making mistakes. One can't learn that way.
I think the article sums it up pretty well and every programmer I know did it that way, well other than learning programming in school, which I myself don't really consider "learning to program", because I never met any person that actually learned programming ins school, meaning if they did they didn't ever program again.
You learned how to code. Great, I am legitimately, truthfully happy for you. It's a very cool skill/career path and a wonderful feeling when you have the ability to create something on your own.
But...do we really need to read that on the frontpage? Am I the only one that finds these types of posts uninteresting?
It has almost become a cliche to wake up and find a frontpage "How I learned <language> in <time> as a <non-programming profession>"
You're probably not the only one, but I rather like many of these posts, and I think they're useful for the large minority or small majority of HN readers who don't program. They're also handy encouragement to non-programmers in general: someone says "I could do it," describes how, and perhaps that'll act as an impetus and example.
Sometimes I learn something new from these kinds of posts.
Then I moved on, briefly, to a Sinclair ZX-81 clone and then stayed with an Apple II until the late-80s. I rented an MSX from the phone company as a videotext terminal. It was a steal at about US$ 7/month.
Also, see http://developers.slashdot.org/story/11/05/11/0358233/is-pro...
In other words, programming to me means so much more than what I give my employer. Just like the article says, it defines a way of life, that puts knowledge, learning and improving on top of everything else.
> "On linux, if you want to copy a file from one box to another, you use scp or rsync"
No, not really... I just SFTP at the moment simply cause I find it more convenient (granted, I'm not a Linux power user in any way).
Was wondering what milestone achievements I should hit in Linux, given my goals? Goal details here:
tl;dr - infrequently-used irregular verbs get "regularized", frequently-used irregular verbs, e.g., "be", "think", will likely stay irregular forever.
(I remember reading about changes to the English language that happened to be underway about the time the printing press arrived, and how the press "froze" that process, leaving us with the mess of pronunciation, spelling, and verb endings we have today, but I've been unable to find an appropriate reference, so I offer the article about the Lieberman study in its place.)
learnt - British
learned - American
UK English: learnt
Disclaimer: this is sarcasm.