Ask HN: Should I learn Rails without a Mac?
I have zero programming experience. I have a HP Pavilion Laptop with Windows 8, and want to take one of the popular online Rails courses. I imagine the instructions, videos, screenshots etc will all be on Macs.
Am I unnecessarily creating additional barriers towards my goal? Should I just bite the bullet and purchase a Mac (which I can do in 3 months)? Learning how to navigate around a Mac will have its own learning curve too. Any advice will help.
59 comments
[ 4.7 ms ] story [ 136 ms ] threadI'd imagine most of the screenshots in the Rails tutorial will be command line stuff.
I have a Xubuntu VM running in VirtualBox on my Windows 8 laptop that I keep around for coding; it's actually a pretty nice setup. I run the VM on my external monitor, and can use the Windows host to do web browsing, play music, etc. while I'm working - I've even made my Dropbox a shared folder with the VM, so the guest OS can use the files but the host OS handles syncing them so there's no edit conflicts.
If you're running in a VM, one of the lighter Ubuntu variants might be a good choice as well - check out Lubuntu or Xubuntu.
That said, the Linux distro you choose doesn't matter a whole lot, they all tend to be pretty equivalent (well, I'd avoid Gentoo and Arch unless you want to learn a lot more than you'd planned on about building packages from source).
I second the idea of Linux, and suggest installing it in a VM under Windows 8. And yes there:s a learning curve, but one driven by necessity and applicable to the world of web applications of which Rails is a part.
Good luck.
https://youtu.be/SKsIvLPqlrc
Then completing this Rails tutorial:
http://ruby.railstutorial.org
Then expanding your knowledge with RailsCasts while developing your own web application:
http://railscasts.com
http://www.groovypost.com/howto/create-virtual-machine-hyper...
It's a lot easier just to dedicate one to school work and dispose of it when done, or clone it another VM is needed.
That way Ubuntu is just another app.
Yes, you are making barriers.
Here's a (referral) link: https://www.digitalocean.com/?refcode=09e94b0118a3
Although I have given my referral link, my recommendation holds whether you choose to go for them or not.
Give VirtualBox a try - it's free. https://www.virtualbox.org/
Personally I like Ubuntu.
As for Linux, lots of people seem to dislike Ubuntu for various reasons, but at the end of the day, googling "ubuntu <something> tutorial" will almost always get you a good solution.
http://www.groovypost.com/howto/create-virtual-machine-hyper...
I imagine this is good enough to get you started.
Once you are ready to move on and start developing on a unix system you can install Vagrant which will give you disposable dev virtual machines running Linux (which will likely be closer to a real deployment environment than a Mac would be). http://www.vagrantup.com/
Your other alternative is to install a full Linux distribution on your computer. Honestly though you are best off using Vagrant in the long run regardless of your primary OS simply to avoid various headaches. Probably even if you use a Mac.
One of the biggest problems for newbies is that filenames in Linux are case sensitive whereas on Mac/Windows they are not.
A Mac is by no means a prerequisite for using Rails. The screenshots might look a little different , but in most cases the important parts will be identical.
This will probably get me downvoted but:
Download a dodgy OSX VM and run it inside VMware.
Then contact whoever is issuing the course and explain to them that the course should be OS neutral.
Either that or find another more friendly course.
So what I did when starting out was use Linux Mint on a virtual machine to learn. It was a pain in the ass but it worked, the speed of the VM was negligible but sometimes I wished I was on a real machine instead of a VM.
When I knew that I would be use Rails for the long-run I bought myself an iMac and haven't looked back. Everything Rails-related runs beautifully because the majority of Rails developer use Mac OSX. You got homebrew, rubymine, sublimetext, the works. I love my dev machine and can't see myself using Linux to develop things on again.
You'll soon realize the value of not using Windows. A big part of learning as a newbie is to just try things out. Then you can understand in a very personal way why everyone on HN is telling you to develop on a linux VM (or Mac when you get it).
You'll also find out that "learning Rails" as someone with zero programming experience really isn't about learning just Rails. It's going to be valuable to learn the command line, git, heroku, etc.
A great resource for a complete newbie is the material from Coursera's "Startup Engineering" class. There's a lot of business-y stuff in it (e.g. market sizing) but you can just ignore that and follow the instructions they give for setting up a decent dev environment and all the tools you'll need to do basic work. The reason it's so great is that they really hold your hand through setting up a lot of the background "infrastructural" stuff that someone with zero programming experience might not be aware of.
Full disclosure, though, I also have a Mac for personal use and I've definitely found Rails development and deployment to be much easier on a linux-like platform than a Windows one.
If you're just setting out learning programming it's a very instructive experience to set up a Linux environment anyway. With modern machines you can "virtualize" an operating system -- basically running linux as a program inside windows -- which gets rid of a bunch of the hassle involved in maintaining a linux desktop. I'd start by installing Ubuntu desktop inside Virtualbox and getting a rails environment set up there. This will give you a much more frictionless rails experience and you'll get to learn a bit about linux in the process.
You may end up buying a mac later on, but there's no reason to delay learning about rails just because of it. Just get started with the Virtual machine, learn a bit about linux, and go from there. Many professional rails developers use linux VMs on their Macs anyway.
Your OS doesn't matter so much when you're first starting out. It'll matter later on when you get the hang of some more intermediate to advanced concepts.
My belief (and a question like this will solicit only beliefs from everyone even if presented as facts) is that you probably want a Unix-like OS if you're getting into any web development. The only exception to that rule is if you're going to be primarily using Microsoft technologies like .NET, C#, IIS, or any other number of MS technologies.
I'll give you a rundown of what I've found the best uses for each OS are. This is coming from someone who prefers a Mac (used at home) and uses both Windows and Linux at work. So I've got a lot of experience with all 3 and have used them all for heavy web development projects.
Windows is just fine to start with. You have access to a lot of high level and mainstream tools like code editors and graphics programs. If you're a point-and-click kind of person you'll have no problem. Problems start to arise when you need to set up a local dev environment that would resemble a test or prod environment. You have to jump through hoops and install non-standard programs to get things like Rubygems, and different Ruby versions running locally. It's not difficult per se but you'll find out what I mean when I say its a hassle if you use any other OS. Also, the command line is sorely lacking on Windows and even tools like Cygwin leave something to be desired at times.
Macs are a great alternative to Windows and my Preferred OS for web development. You get a beautiful interface that's relatively easy to switch over to from Windows. You still get all the power of GUI tools plus the vast majority of Unix-y tools under the hood. It's great for design (you can run Photoshop and other great tools natively) and you get equal or better variety of code editos like Wondows. Where the Mac really shines is once you start playing with the terminal. You've got almost all of the Unix tools you'd have in a prod environment installed by default and you can run things like RVM, Rbenv, and server stacks like AMP (apache, MySQL, PHP) or Nginx instead of Apache and generally just replicate a standard Ruby stack locally through the command line like you would in Linux or with MAMP-style programs. It lacks a decent package manager but tools like Homebrew take care of that for you. Macs, to me, are like Linux distros with top notch desig tools (and minus the freedom but I'm not speaking philosophically here).
Linux distros are very similar to OS X in a lot of ways but have extra Unix tools pre installed that a Mac doesn't have (but can get). They're not always the prettiest and its rare that a designer prefers them (I mention design because for me its a standard part of development) but they're usually the most powerful when it comes to the 3 main OSes out there today. By power I don't mean speed and the ability of the software to take advantage of the hardware. I mean it gives you powerful tools and an unspoken but understood "Unix Way" of doing things. There is a bit of a learning curve however. A local development environment on a Linux machine will most likely best mirror anything you'd publish online.
I went from Windows to Mac to Linux when I was learning web development. Windows let me jump right in with the real simple high level stuff but then gave me trouble when it was time to get more advanced. My Macs let me get all the way to an expert level and never got in my way. I was actually able to learn a lot about how Linux works on a Mac and transfer those skills over so when I got into Linux I was very comfortable. Linux taught me even more valuable skills, many of which I brought back to the Mac.
In the end I chose Mac as my preference because for me its a great middle ground between the absol...
Or when you want to install any gem with a C extension, like mysql2 or nokogiri, which many tutorials will steer you towards in the first 30 seconds.
If you can do remote dev, then a cheap VPS might make sense, however this means that you need to be learning somewhere with 'net access.