What are the components in the Ruby on Rails ecosystem?
-
I've been reading a bit about Ruby on Rails development on Mac OS X, but I'm discouraged with trying to make sense of many components in the ecosystem. Here is just a small choice: - rvm (a virtual environment of some sort?) - rbenv - ruby build - bundler - pow (probably a small server - what about the database?) - rspec (unit tests?) I'd like to hear what each piece does, why, and how does it fit to the whole.
-
Answer:
RVM and rbenv are both libraries that allow you to work with multiple versions of the Ruby language on a single machine. They simplify the building and installation of new Ruby versions as they come out and are useful for engineers who work on multiple projects that may have different Ruby versions running in production. Bundler is a dependency management tool that allows you to quickly and easily define the libraries a project needs. It will automatically resolve version conflicts and download all appropriate gems from the sources you provide. Pow is an OS X specific tool for easily running multiple apps in a development environment without having to constantly start and stop servers. RSpec is a testing framework that has grown very popular in the Ruby community.
Michael Bleigh at Quora Visit the source
Other answers
So got most of it. I'll take a step back and give the higher level overview. Rails is a web application framework written in ruby. So, you'll need ruby. Most system rubys are version 1.8.7ish or 1.9.2. The latest are 1.9.3 and 2.0.0 (pre). Once you start doing any amount of work with ruby you'll likely need multiple versions. To that end there are several ways to maintain multiple versions without going crazy. RVM and rbenv are, currently, the most popular way to do that.. For most apps, you'll need a database. The world is your oyster hear and you can use just about anything, Sqlite3, MySQL, Postgresql, MS SQL Server, Oracle as well as all the MongoDB/CouchDB and variants. To avoid rewriting a bunch of existing code, or to shorten development cycle you'll be interested in ruby gems. Gems are packages, similar in a way to apt-get, yum or Perl's CPAN. To get around version conflicts in multiple projects bundler was born. Testing, and TDD/BDD in particular are big focuses in the community and there are loads of tools to help you test. Rspec, minitest, minispec, bacon, test::unit, cucumber, capybara are just a few. There are also gems to help manage test data and mocking out 3rd party calls like FactoryGirl, Machinist, VCR and Fakeweb. Finally, you'll need to serve up your app. There are dozens of ways to do that. But generally you need a web server and an app server. Pow is strictly for development and helps keep projects straight with symlinks and domain names. But you can use apache or nginx as the webserver (and others) in front of an app server like unicorn, puma, thin, mongrel etc.
Jeff Schoolcraft
Related Q & A:
- What Are The Components Of Health?Best solution by Yahoo! Answers
- how to use ajax with json in ruby on rails?Best solution by Stack Overflow
- What is the difference between a biome and an ecosystem?Best solution by Yahoo! Answers
- What are the components in a topographical survey?Best solution by answers.yahoo.com
- What are the components of a car battery?Best solution by Yahoo! Answers
Just Added Q & A:
- How many active mobile subscribers are there in China?Best solution by Quora
- How to find the right vacation?Best solution by bookit.com
- How To Make Your Own Primer?Best solution by thekrazycouponlady.com
- How do you get the domain & range?Best solution by ChaCha
- How do you open pop up blockers?Best solution by Yahoo! Answers
For every problem there is a solution! Proved by Solucija.
-
Got an issue and looking for advice?
-
Ask Solucija to search every corner of the Web for help.
-
Get workable solutions and helpful tips in a moment.
Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.