TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Ask HN: Should I learn Rails without a Mac?

13 点作者 prakster将近 12 年前
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.<p>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.

17 条评论

simonw将近 12 年前
It&#x27;s absolutely worth learning to use Linux in a VM for this kind of development work - you&#x27;ll be deploying on Linux anyway, so it makes sense to use that as your development environment as well.<p>Give VirtualBox a try - it&#x27;s free. <a href="https://www.virtualbox.org/" rel="nofollow">https:&#x2F;&#x2F;www.virtualbox.org&#x2F;</a><p>Personally I like Ubuntu.
评论 #6152782 未加载
评论 #6152707 未加载
评论 #6152730 未加载
评论 #6153737 未加载
评论 #6152808 未加载
评论 #6152811 未加载
评论 #6152773 未加载
tryitnow将近 12 年前
You&#x27;re probably excited about learning rails - if so, just go ahead and jump into it. Like right now, don&#x27;t worry about anything else.<p>You&#x27;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).<p>You&#x27;ll also find out that &quot;learning Rails&quot; as someone with zero programming experience really isn&#x27;t about learning just Rails. It&#x27;s going to be valuable to learn the command line, git, heroku, etc.<p>A great resource for a complete newbie is the material from Coursera&#x27;s &quot;Startup Engineering&quot; class. There&#x27;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&#x27;ll need to do basic work. The reason it&#x27;s so great is that they really hold your hand through setting up a lot of the background &quot;infrastructural&quot; stuff that someone with zero programming experience might not be aware of.
评论 #6152806 未加载
评论 #6152745 未加载
bpatrianakos将近 12 年前
The short answer is do it right now with whatever tools youve got and learn what you need to learn to get a Rails app up and running.<p>Your OS doesn&#x27;t matter so much when you&#x27;re first starting out. It&#x27;ll matter later on when you get the hang of some more intermediate to advanced concepts.<p>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&#x27;re getting into any web development. The only exception to that rule is if you&#x27;re going to be primarily using Microsoft technologies like .NET, C#, IIS, or any other number of MS technologies.<p>I&#x27;ll give you a rundown of what I&#x27;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&#x27;ve got a lot of experience with all 3 and have used them all for heavy web development projects.<p>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&#x27;re a point-and-click kind of person you&#x27;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&#x27;s not difficult per se but you&#x27;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.<p>Macs are a great alternative to Windows and my Preferred OS for web development. You get a beautiful interface that&#x27;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&#x27;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&#x27;ve got almost all of the Unix tools you&#x27;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&#x27;m not speaking philosophically here).<p>Linux distros are very similar to OS X in a lot of ways but have extra Unix tools pre installed that a Mac doesn&#x27;t have (but can get). They&#x27;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&#x27;re usually the most powerful when it comes to the 3 main OSes out there today. By power I don&#x27;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 &quot;Unix Way&quot; 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&#x27;d publish online.<p>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.<p>In the end I chose Mac as my preference because for me its a great middle ground between the absolute raw power of the Unix Way and its great GUI and support for design tools. I could use Linux and Mac with about equal ease and efficiency but Windows still cramps my style to this day no matter how much effort I put into learning its tools or &quot;way&quot; of doing things.<p>My advice to you is to worry about this decision later. You probably don&#x27;t have enough experience to know what you&#x27;re missing and what you&#x27;d prefer. And before switching from Windows to anything else just try what&#x27;s out there. Macs always look great in theory but wonderful as they are they&#x27;re not always for everyone. (I do have a feeling you will make a switch one day to something other than Windows no matter what - I say this because I&#x27;ve seen it many times and its not common for a web developer to prefer Windows unless, like I mentioned, you&#x27;re using a primarily MS-based tech stack).<p><i>The views expressed herein are my own and not meant to start a religious war over OS choice. To each his own and there aren&#x27;t any right answers.</i>
评论 #6152919 未加载
评论 #6153164 未加载
jiggy2011将近 12 年前
There is a ruby installer for Windows <a href="http://rubyinstaller.org/" rel="nofollow">http:&#x2F;&#x2F;rubyinstaller.org&#x2F;</a> , so you can just install that and then do &quot;gem install rails&quot; from the command line.<p>I imagine this is good enough to get you started.<p>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). <a href="http://www.vagrantup.com/" rel="nofollow">http:&#x2F;&#x2F;www.vagrantup.com&#x2F;</a><p>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.<p>One of the biggest problems for newbies is that filenames in Linux are case sensitive whereas on Mac&#x2F;Windows they are not.<p>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.
评论 #6152735 未加载
stevepike将近 12 年前
You want to do rails development on a nix system, which basically means Linux or Mac. Developing on Windows will be frustrating: some gems won&#x27;t work (especially ones that call C code written for a nix environment), everything will run slower, and many tutorials will be confusing.<p>If you&#x27;re just setting out learning programming it&#x27;s a very instructive experience to set up a Linux environment anyway. With modern machines you can &quot;virtualize&quot; 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&#x27;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&#x27;ll get to learn a bit about linux in the process.<p>You may end up buying a mac later on, but there&#x27;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.
评论 #6152779 未加载
hikari17将近 12 年前
You could try the RailsInstaller (<a href="http://www.railsinstaller.org/en" rel="nofollow">http:&#x2F;&#x2F;www.railsinstaller.org&#x2F;en</a>) project from Luis Lavena. I went from essentially zero webdev experience to completing Michael Hartl&#x27;s Rails Tutorial to building modest production applications in Rails on my Windows 7 PC at work with RailsInstaller as my starting point. It hasn&#x27;t been problem-free, but I&#x27;ve been able to get great support through the RailsInstaller Google group.<p>Full disclosure, though, I also have a Mac for personal use and I&#x27;ve definitely found Rails development and deployment to be much easier on a linux-like platform than a Windows one.
评论 #6152763 未加载
div将近 12 年前
In a pinch, Windows will do, but your best option is probably to find a nice Linux distro and get comfortable with that. It will allow you to follow along with the command line, and when the time comes, it&#x27;s an easy switch to a Mac.
评论 #6152635 未加载
sergiotapia将近 12 年前
Windows used to work when running Rails but then it broke again for some reason. That&#x27;s just the way it is with Rails, since very few people use it on Windows, Windows bugs are taken care of extremely slowly.<p>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.<p>When I knew that I would be use Rails for the long-run I bought myself an iMac and haven&#x27;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&#x27;t see myself using Linux to develop things on again.
评论 #6152760 未加载
joshka将近 12 年前
Probably the simplest approach that lets you do local dev is VirtualBox + Vagrant + an Ubuntu box. This combination shouldn&#x27;t take a great deal of time to setup (10-20 minutes + download time), is pretty much zero cost and means you can use the laptop that you currently have.<p>If you can do remote dev, then a cheap VPS might make sense, however this means that you need to be learning somewhere with &#x27;net access.
brudgers将近 12 年前
Three months from now, you can be a bit knowledgeable in Rails or own a Mac. Which is the better option depends on what you really want to do and how much effort you want to put forth.<p>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.<p>Good luck.
评论 #6152644 未加载
harrytuttle将近 12 年前
Don&#x27;t buy a mac for this. It&#x27;s an expensive way to solve the problem.<p>This will probably get me downvoted but:<p>Download a dodgy OSX VM and run it inside VMware.<p>Then contact whoever is issuing the course and explain to them that the course should be OS neutral.<p>Either that or find another more friendly course.
评论 #6152799 未加载
adyus将近 12 年前
If you don&#x27;t want to bother with VMs and other Windows workarounds, I can suggest signing up for <a href="http://action.io" rel="nofollow">http:&#x2F;&#x2F;action.io</a> and getting a basic development server. You can then use PuTTY or their own web IDE to connect to the machine and start developing.
rdouble将近 12 年前
I&#x27;d suggest a VM with Samba mount and Sublime Text. I&#x27;d suggest this setup even if you&#x27;re using a Mac because then you can match your deployment environment.
ibstudios将近 12 年前
Get a vps. For 20-30 usd you have a machine on the internet to play with.<p>Yes, you are making barriers.
评论 #6152665 未加载
throwaway1979将近 12 年前
Here is my suggestion: use virtualization software and run an ubuntu vm. Deploy code to Heroku.
评论 #6152688 未加载
wildster将近 12 年前
Sublime Text and Ubuntu is not a bad choice.
dylanhassinger将近 12 年前
learn rails however you can, then do some freelance work and buy a Mac ASAP