The Ruby and Rails community linklog
Made a library? Written a blog post? Found a useful tutorial? Share it with the Ruby community here or just enjoy what everyone else has found!
Submit a post
Post Preview
Note: Only the first pargraph is shown on the front page and overly long paragraphs may be broken up.
Using rails to build an API
Some thoughts on using Rails to build an API, and other observations I had while building one.
Top 7 RSpec Best Practices
It’s really hard to overemphasize how helpful RSpec is and how much easier becomes your life if you have good specs coverage. But its outstanding flexibility enables many ways to make your specs awful: horribly slow, over-bloated, even non-readable sometimes. In this article I will give you some ideas how to improve your specs quality and increase efficiency of your BDD workflow.
Pancake - stacken them up
I came across Pancake today and feel it could be a game changer on developing rack based applications. Here is extracted from its readme: [more inside]
XML Feed and Documentation in Rails
Learn how to add a simple XML feed and generate documentation on your Rails application here!
Rango 0.1 Released!
I am happy to announce the first public release of my new framework Rango. Rango is a small MVC framework inspired by Merb and Django builded on top of Rack. It’s clean, simple and it’s trying to be as agnostic as possible. It has Bundler support and mainly, it’s the only Ruby framework with template inheritance! [more inside]
Stubbing and Setting Expectations on HTTP Requests Is Now Easy With WebMock
Is your application making HTTP requests? Are you also tired of writing complex tests with HTTP library methods stubbed? Do you end up testing implementation of Net::HTTP or other HTTP libs instead of testing behaviour? Do you have to change your tests or specs any time you change your HTTP library, even if behaviour doesn’t change? I had the same problems so I created WebMock gem.
Phuby on Phails video from RubyConf
Here is my Phuby on Phails demo video from RubyConf
Administration system in Rails
Learn how to create a simple but effective administration system in Rails here. Make sure you check out the other tasks on how to create an online depot applocation in my Rails Learning Experience!
Rack::Rewrite + Google Analytics Makes Site Transitions Seamless
Learn how to very simply ensure that a site rewrite or transition is executed smoothly by leveraging Rack::Rewrite and Google Analytics.
Check your scripts with JSLint on Rails
Did you have a feeling that you should be running JSLint on your Javascript code, but you never had time to integrate it with your Rails project? Now you have no excuses: Check your scripts with JSLint on Rails (GitHub page: http://github.com/psionides/jslint_on_rails).
Overridable, say goodbye to method alias
I just released a gem called overridable on Gemcutter.org, that gem helps you make your methods to be overridable by including modules. So you can dismiss things like alias_method_chain. Give it a look.
Transition from #ruby to #jruby on #rails on #torquebox.
JRubyist Dan Tylenda-Emmons wrote a small article including a handy ruby script to help you transition from ruby on rails to an enterprise class jruby on rails deployment environment. The script will download and install torquebox, set up your paths for you, and install jruby-openssl in an automated process.
Fukuoka Ruby Award - Deadline Extended
Fukuoka Ruby Award Submission Deadline Extended to DECEMBER 4, 2009. Visit http://www.f-rubyaward.com/index_en.html for more info.
Jekyll: Sites Made Simple
Sitepoint has published an article on Jekyll, a static site generator. It goes in detail on installing Jekyll, creating the basic structure, testing the site locally and deploying. It even has a short introduction to Liquid, the tagging engine used by Jekyll. I have found this to be the best available walk-through on Jekyll till now. Check it out here.
Authenticated S3 GETs For Private Objects Using Paperclip
A solution on how to use both security through obscurity, your own controller access control and finally AWS::S3’s own authenticated GETs for private objects all using the popular paperclip gem.
Boson 0.2.1 Released
Boson is a unique command framework whose commands are written in plain ruby and usable from the commandline and irb. The latest release introduces more features that are unique to command frameworks: powerful one-liners, custom option types, library dependencies, pipe options, etc. Boson also comes with newfound querying capabilities which make it easy to build Ruby reference commands.
HTML Sanitization In Rails That Actually Works
A sanitizer for Rails that escapes unauthorized and unclosed tags, stopping (clueless malicious) users dead in their tracks. Read more, including source code »
Deep In Rails: ActionMailer#deliver Part II
When we left off last, we were just about to get into rendering the message. Let’s recap that code … read more »
Amp - Mercurial rewritten in Ruby. Easily customizable. Open to contributors!
We’ve been working for about 8 months on-and-off on a project we’re really excited about: Mercurial, re-written in Ruby from the ground up. It’s called Amp, and it’s out in beta form! [more inside]
Sass Supports Rack
Sass, the CSS precompiler, now supports all Rack-based frameworks.
New Screencast: Introduction to MongoDB - Part I
In this screencast, you will see the basic CRUD operation using MongoDB shell. This is the first installment of a series on MongoDB. Watch the screencast at TeachMeToCode.com
Using Amazon RDS with Heroku / Rails
Amazon has a MySQL service. It scales up to 68gb ram and deals with backups for you. Heroku lets you use this. Instead of paying $200/month for the Ronin DB, you can just make your own db with RDS on aws and only pay for dynos from heroku and not have to deal with migrating to posgres. Check out how easy it is.
Blueprints - new replacement for fixtures and factories
A new replacement for fixtures and factories Blueprints has been released. You can check it on github or read an article I wrote about it
A uniquely powerful Ruby parser for Temporal Expressions.
Just released a new Rubygem: Temporals can parse quite complex natural-language (English) temporal expressions, such as “2:30-3p every mon and wed and 3-3:30 on friday” and “1st-2nd and last Thursdays of March and April 5-6:30pm and March 16th - 24th at 2-2:30”.
Public Alpha of MagLev Released
Though first announced in early 2008, the highly anticipated super-implementation MagLev has finally got its first public alpha release. I’ve written about it on Ruby Inside and shown how to get it running.