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.
Eventable 0.1.3 - Adds non-blocking callbacks
Eventable is the easiest way to add events to your Ruby classes. Update 0.1.3 adds threaded callbacks. This drastically improves Eventable’s performance and keeps long running or malfunctioning callbacks from stopping other callbacks or events from firing. Github: https://github.com/mikbe/eventable && RubyGems: https://rubygems.org/gems/eventable
Improve Rails Asset Caching with MD5 and virtual folders
/foo.jpg -> /asset-v123af/foo.jpg (or /foo.jpg?123af) - MD5 only changes on content-change and is identical on all servers. Folders are CDN/proxy/… cacheable and transparent via nginx/apache rewrite rule. For Rails 2 + 3.0: virtual asset paths
Quick Win: Get Your Conditions in Order
It’s so simple… yet often overlooked. Put your conditional expressions in the right order and get an immediate performance bump. More in our latest blog post.
GemAWeek Episode 4 - Navigasmic
Just posted the fourth episode of GemAWeek. This week I get all navigasmic by semantically creating list-based navigation.
Invite Facebook Friends using Omniauth and FB JS SDK [Screencast]
I just posted a screencast on how to Invite Facebook Friends with Omniauth and the Facebook JS SDK. It builds on Ryan Bates’ railscast Simple OmniAuth.
Using the Google Authenticator app with Rails
Following on from last weeks post on Two-factor Authentication with Rails this new post adds support for the Google Authenticator app for Android, iPhone and Blackberry.
Building Structured API Clients with API Smith
Darcy Laycock of the Frontier Group offers an introduction to API Smith, a simple way to quickly build structured API clients on top of HTTP Party and Hashie.
Fighting Software Erosion with Explicit Contracts (The New Heroku, 4/4)
An exploration of software erosion (aka “bit rot”) in Ruby web apps, and how explicit contracts separate app from infrastructure and provide resistance to erosion over the long term. Part of a four-part series “The New Heroku.”
jQuery tip: sanitize input fields
Short, easy and straight to the point. Sanitize input fields with jQuery
Building a Rails server with Puppet
A short write up of my experience learning and configuring Puppet to build and manage servers to serve Rails applications.
Conferences and accessibility
2 small asks of anyone organising a conference: Conferences and accessibility: please try harder
Rails: store dates in UTC and display them in local time onto client side
A tiny note about how to work with UTC dates in Rails and how to process and display them in local time on the client using javascript.
Ruby File IO API
I just launched a series detailing the Ruby File IO API.
Building a Public API in Rails 3
Just wrote up a detailed tutorial about building a public JSON/XML API on the Miso Engineering blog using Rails 3, OAuth, and the RABL gem for creating the response templates. Figured since we just built our fully fledged Public API with several available third-party applications available, that we should document some of our experiences. Let us know what you think and if there are any other related topics you’d like us to post about.
Spinning Up Cloud Compute Instances
Computation provides raw resources for innovation. Refining resources into services is serious business. Geemus explains how fog simplifies this process of utilizing resources, while smoothing out differences between providers so you can focus on creating the next revolutionary cloud service.
Cleanly add logging to your method calls with metaprogramming
If you’re running your Ruby scripts on a cron job, it’s important to log the output in case something goes wrong. Recording the output is as simple as appending “> somefile.txt” to your cron job. But can you avoid cluttering your code with lots of “puts” statements? Using a bit of metaprogramming, you can write a module that adds logging to whatever methods you specify. In this blog post, I’ll show you how.
Do you indent methods under private?
Which style do you follow? Feel free to fork and show an example if you do something different.
Chef Solo tutorial: Managing a single server with Chef
Chef’s documentation is a bit complex, so I wrote up a Chef tutorial to get you started.
I just launched a blog article about Rai...
I just launched a blog article about Rails basic Authentication system : part 2 for begginers.
Bucket scope pattern in rails
Short write up on the bucket named scope pattern we use in our rails app. Bucket Named Scope Pattern
Dakar Ruby User Group updated
I just updated the Dakar Ruby Brigade .
Compute broadcast calendar dates with Ruby
Just released a smal broadcast_calendar gem to help you compute which civil dates line up with which broadcast calendar dates. Broadcast calendars are used to normalize radio and TV advertising schedules.
Why PHP is (so much) more better than Ruby?
Why PHP is (so much) more better than Ruby? (Slideshare)