EXTENDING RAILS GEMS AND PLUGINSWednesday, October 5, 2011
TYPES OF EXTENSIONS • Plugins / Gems • intializers • dynamic conﬁguration • “monkey patching”Wednesday, October 5, 2011
GEMS VS. PLUGINS • Older versions of Rails required a plugin for some extensions • If there is both a plugin and a gem, use the gem • If there is only a plugin, it is likely a sign of inactivityWednesday, October 5, 2011
IS IT GOOD? 1. Unlike proprietary software, great extensions don’t require the backing of a corporation e.g. tenderlove (Nokogiri), carlhuda (Bundler) 2. On www.rubygems.org? Number of downloads? 3. Source on github? Number of forks? 4. Multiple committers? Freshness of activity? 5. Tests? Do tests pass? 6. Is there a mailing list? Activity? 7. Is there an issues list? Activity?Wednesday, October 5, 2011
USING GEMS Often as simple as 1. Update the gemﬁle 2. bundle install 3. rails g whatever For example: https://github.com/blazingcloud/devise-exampleWednesday, October 5, 2011
A particular slide catching your eye?
Clipping is a handy way to collect important slides you want to go back to later.