Resources for Getting Started with Ruby on Rails
engineyard.comI started learning Rails a few months ago, just before version 3 came out. My #1 tip - install Ruby Version Manager! Playing around with various different versions of Ruby, Rails and various gems, I managed to get my setup into a pretty broken state more than once. RVM lets you manage multiple Ruby installs on the same machine, which basically means that if you screw something up (or find out that a gem you needed to use won't work right with your version of Ruby/Rails) you don't have to reconfigure your entire machine.
If I had taken the time to install it straight away I would have saved a lot of wasted effort.
haha, yea RVM is an amazing tool. I'm working on creating a tutorial for setting up your local machine to have it ready to start working on RoR. I just need to do a little more research about the best ways to do it for Windows since that is an OS I'm not to familiar with.
A tutorial would be great. I couldn't figure RVM out from the messy docs; had to have others step me through the install and set-up process.
On Windows? rvm is *NIX only. You can use Pik, though: https://github.com/vertiginous/pik
Here's my 'rvm tutorial in a HN comment':
To install rvm, run this:
Then add this to your .bashrc, at the bottom:$ bash < <( curl http://rvm.beginrescueend.com/releases/rvm-install-head )
Open a new shell and you should be golden. Never 'sudo gem install' again![[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm"To install any Ruby, 'rvm install 1.9.2', for example. To switch Rubies, 'rvm 1.9.2'.
That's it! Pretty easy. I like to take two further steps, though: create a gemset per application, and set up .rvmrc files to switch to the right ruby automatically.
To do the gemset thing, 'rvm gemset create gemset_name'. You can switch to a specific gemset at the time you switch rubies with 'rvm 1.9.2@gemset_name', or after with 'rvm gemset use gemset_name'
Once you've got that going, make a '.rvmrc' file in the root of your project, and put in it the rvm command to switch to your ruby/gemset. "echo 'rvm 1.9.2@gemset_name' > .rvmrc" is probably the easiest way to do this. Then, when you switch to your project, you're in the correct ruby and gemset automatically. When you have 9 or 10 projects on 4 different Rubies, this helps a lot...
A tutorial would be great, but a tutorial that also explained why we are doing each step would be amazing. My Linux/Unix knowledge is somewhat limited, so a short tutorial really breaks down if I hit a step that doesn't work because of some different configuration on my machine.
Then what should have been ten minutes turns into three hours and I burn up all the time I could have been building something. Granted I usually learn something along the way, but it would be awesome if people provided some more details as part of their tutorials.
That's exactly my experience with linux/unix tutorials also. They tend to give an exact, step-by-step account of what to type in to the shell, with no explanation whatsoever of what any of the commands actually do. Then you find that something has slightly changed with the latest version of package xyz, and you're lost.
There are other places with nice screencasts, like :
- Teach me to code: http://teachmetocode.com/
- Lernivore: (this is an aggregator) http://learnivore.com/
Even they are not rails specific I found this interesting:
- Katacasts: http://katacasts.com/
- Remi: http://remi.org/ (I think he has stop uploading anything new)
- Vimcast: http://vimcasts.org/
- Ruby Pulse: http://rubypulse.com/
I also like to check out Confreaks to see the sessions of some conferences
I also recommend this website for a good collection of blogs entries daily. http://www.planetrubyonrails.com/
Good list. There's a few sites I haven't been to yet. Not a fan of bit.ly links though. I like knowing exactly where the links are going to
Yea, I realize that know. I think I'm going to add the urls next to the links so people know where they are going.
Why use shortened links at all if no users have to type them? You've added the complete links now, but they're not clickable.
Indeed. This is really bizarre behaviour. The full links are shown in non-clickble text beside the links. But the links actually point to shortened bit.ly links. What's the point of using shortened links here at all?
from the comments on the blog:
-- quote --
Hey Matt,
Thanks, glad you find it useful. My reasoning for the bit.ly links is so that I can see what types of resources readers of the EY blog find interesting so that I can cater future posts and tutorials with that in mind. I know that google analytics does the same thing, but I myself do not have access to that and all I need to know is what links were clicked on not everything else.
I did not expect people to find the bit.ly links annoying. Is there something about them I am missing? I wouldn't have done it if I thought people would find it to be an annoyance.
-- end quote --
If you are a beginner, the rails tutorial is just awesome. It describes every step you take - really, really great stuff.
Do you mean: http://railstutorial.org/
I updated the post so that you know where the links are taking you.
In case you find it useful:
http://www.learnivore.com aggregates most of the ruby/rails programming screencasts I could find (disclaimer: I'm running this site).
I have updated the post to have the base url for all the resources. My apologizes to the creators of those resources. My intentions were never to take away from your PageRanks.
Also, I will be adding resources recommended by people in the comments on the post, HN, and Reddit shortly. So if you have any you want added let me know soon.
Updated the post to include suggestions by commenters on the blog, HN, and twitter.
Why's Poignant Guide to Ruby and Foundation of Rails 2, should be on that list.
That link doesn't work for me. Anyone else having issues?