就目前而言,我是一名Java和c#开发人员。我对Ruby on Rails看得越多,我就越想学习它。

你发现学习RoR的最佳途径是什么?在Windows上开发会更容易吗,还是应该在Linux上运行虚拟机?

是否有一种IDE可以与Visual Studio的健壮性相匹配?有什么程序可以给我们一个很好的开销吗?有什么好书吗?

说真的,任何建议/技巧/咆哮都很棒。


当前回答

我发现Obie Fernandez写的《The Rails Way》非常棒,当使用Rails进行敏捷Web开发还不够深入的时候,我经常会参考它。Obie Fernandez也有一个不错的博客。

其他回答

这里有很多好意见。我要加上这里没有的。我的经验:

Rails on Windows is easy to get going with RailsInstaller, especially if you're using SQLite. If you want to use Ruby gems which need C extensions (e.g. RMagick), installation is difficult and unpredictable. PostgreSQL is a pain to install on Windows, and a pain to hook up to Rails. git doesn't work quite right on Windows. IDEs are bulky (Aptana). Notepad++ is good enough. Rails on Ubuntu is easy, and gems requiring C libraries just work. If your computer is powerful enough, use VirtualBox or VMWare Player, and use an Ubuntu Virtual Machine.

设置资源

本页面展示了如何在Ubuntu 11.10上安装Ruby/Rails/PostgreSQL。 如果你不喜欢RVM(我不喜欢),使用rbenv。RVM和rbenv是用于管理多个Ruby版本的工具,包括JRuby、Rubinius等。

用于开发/测试的实时部署

实时部署可以让你的朋友试用你的应用。它也可以让你更容易与需要回调到Rails服务器的web服务交互(如PayPal IPN或Twilio)。 Heroku.com是我最喜欢部署的地方。 localtunnel.com是一个很好的实用工具,可以将一个公开可见的URL指向本地Rails服务器。(我只在基于windows的Rails服务器上使用它)。

学习

试试网上的教程。 使用stackoverflow.com来提问。 使用“raise Exception, params”。to_s”在你的控制器中停止应用程序,打印出驱动你的控制器的所有参数。这让我对如何在Rails应用程序中来回传输数据有了最深刻的了解。 使用Rails控制台(“Rails控制台”)检查数据,并在将代码片段嵌入模型或控制器之前试用它们。

我在很久以前看过臭名昭著的“15分钟写博客”视频,当时Rails大概还在1.0版本左右。关于Ruby/Rails世界最重要的事情之一是,鉴于它是一个伟大的社区,与其他框架相比,它的变化速度快得可笑。

今天,Rails与过去相比有了很大的不同,尽管其主要意识形态一直保持不变。尽管在过去的几年里我学到了很多关于Rails的东西,但我仍然在不断地学习关于它的新东西。

对我来说,帮助我发现并跟上Ruby和Rails的最新方法的最有价值的资源如下:

Rails Guides - A nice way of learning Rails itself, edited by the community, moderated by the core contributors. The site has a lot to offer on most of the important main topics around Rails that it can get you up and running very quickly. It covers bot the most recent stable and edge versions of the framework. If you understand the main ideology of Rails than I definitely recommend checking out (and subscribing to) Ryan Bates' Railscasts. Let me just quote from the site itself, I think it's pretty self explanatory: Every week Ryan Bates will host a new Railscasts episode featuring tips and tricks with Ruby on Rails. These screencasts are short and focus on one technique so you can quickly move on to applying it to your own project. The topics target the intermediate Rails developer, but beginners and experts will get something out of it as well. There are also a lot of podcasts around Ruby/Rails, the two that I keep listening to are Ruby5 and the Ruby Show. For more specific questions like API calls etc, I'd recommend APIDock's Rails and Ruby sections where you can get more information on specific methods. If you are getting more familiar with the framework, it's worth taking a look at Rails Best Practices. There's a bunch of short articles on certain issues that most people make in the beginning of their learning curve with Rails. This site is meant to point pot these issues and help beginners finding their way towards writing better and more well thought out code. There's also a gem that you could use which scans your application and points out these issues and offers solutions/workarounds. Pretty neat!

这些资源应该可以帮助您建立和运行Rails。祝您在Rails世界的旅程中好运,欢迎来到这个社区。

阻力最小的路径:

Have a simple web project in mind. Go to rubyonrails.org and look at their "Blog in 15 minutes" screencast to get excited. Get a copy of O'Reilly Media's Learning Ruby Get a Mac or Linux box. (Fewer early Rails frustrations due to the fact that Rails is generally developed on these.) Get a copy of Agile Web Development with Rails. Get the version of Ruby and Rails described in that book. Run through that book's first section to get a feel for what it's like. Go to railscasts.com and view at the earliest videos for a closer look. Buy The Rails Way by Obie Fernandez to get a deeper understanding of Rails and what it's doing. Then upgrade to the newest production version of Rails, and view the latest railscasts.com videos.

在guides. Rails .info上阅读所有的指南,从Getting Started with Rails开始。它们写得很好,组织得很好,而且是最新的。