Not sure what happened but when I upgraded to Mavericks it says that Rails it not install. I executed the following command:
rails --version
It wasn't working for me even when I reinstalled xcode and the command line tools for mavericks.
But after that, I just did a bundle update and, for some reason, it worked.
bundle update