RubyFlow : The Ruby Community Blog

Home   Submit   Sign Up   Log In   leaders   Twitter   RSS Feed  
 
May 21, 2013
An introduction to reducing your Rails test suite run time.
Once you get started with Cucumber, the question is how to write your features. How can you keep your features maintainable so you don’t have to correct them after each change in the application? How can you reuse steps most efficiently? What are typical Cucumber smells?

Following is a list of 5 best practices that can help in your daily Cucumber life.

Top 5 Cucumber best practices
Writing clean view code in Ruby on Rails is hard. More often than not, the separation between style and structure doesn't work out as intended. Some user interface widgets are just not easily expressed with a few HTML tags. I just published a blog post describing how you can build powerful helpers that will clean up your view code a lot.
Taming Rails Apps with Engines  blog.socialcast.com
I just wrote a blog post, Taming Rails Apps with Engines, about using Rails Engines to break down a large Rails project.
Find out how to test your libraries against multiple versions of Rails so your gems will be ready when Rails 4 comes out.
This blog post details how you can use Cloudinary to perform asynchronous background image processing in the cloud and receive web notifications when uploading and image manipulation are completed. Sample code in Ruby is included.
May 20, 2013
Searchlight is a lightweight gem for building searches in your app. Searchlight follows the same philosophy as Authority: low-magic, very little DSL. Mostly you'll write plain Ruby methods for your logic; Searchlight just helps you tie it together.

Searchlight integrates nicely with ActiveRecord and Rails forms, but can be used in any Ruby program. Check it out on Github or Rubygems.
There are many options when it comes to building authentication into you rails app. A popular option is to use devise, but for more simple projects, Rails inbuilt has_secure_password feature is a valid option. I blogged about it.
May 19, 2013
A small nifty gem equatable to help value objects express their equality.
I just released github_api with support for media types, statistics api and more.
May 18, 2013
Building a Tested, Documented and Versioned JSON API Using Rails 4
Blog post
If you have objects bigger then 1MB try large_object_store!
May 17, 2013
Why ruby 2.0.0 runs slower than 1.9.3? (hint: because I have asked it to be slower). In fact, it's nearly as fast as 1.9.3 with falcon-gc.
I just pushed chef-handler-librato 1.1.6 update with some minor bug fixes.
We've just written a blog post about Futuroscope, a new Ruby gem that makes working with parallelism a piece of cake.
The gem macros4cuke allows you to define macro-steps directly in your Cucumber scenarios without fiddling step definitions. Data arguments can be passed from the macro-steps to their sub-steps. Macro-steps can invoke other macro-steps, sub-steps can be made conditional... More details and examples can be found here.
May 16, 2013
Discover Bower and how to integrate it in your rails app.
I just released a new tutorial Upload and Parse a XML File with Ruby on Rails, Paperclip and Nokogiri. Please take a look.
Chef.bscott.me  chef.bscott.me
I just launched Chef Daily Newspaper , Content will start showing up shortly.
May 15, 2013
Ruby Daily goes mobile  stream.rubydaily.org
Yesterday I’ve rolled out a couple of features for my ruby and web development news project - Ruby Daily. Hope you find them cool and useful.
Feel free to submit new articles or subscribe to newsfeed.
This blog will take you through the process of setting up alternative authentication system for your application using service providers like FB, Twitter.
May 14, 2013
Most of us developer types have at least two machines we use routinely, and managing that can be a chore. Homeboy is a set of small, plain BASH scripts to synchronize core config files, update system packages, upgrade development libraries, and pull git clones every morning in one shot by running `homeboy'. [release overview] [github]

I just launched some groovy thing and yada yada.
In this screencast we look at the two Selenium tools Selenium IDE and Selenium WebDriver. Selenium is a remote control for your browser. Selenium lets you perform browser actions by creating scripts instead of using your mouse or keyboard. Let's have a look!

Test your web apps with Selenium
If you have a Rails side project hosted with Heroku and you're using the basic or dev database with the fixed row counts, you might want to consider reading this post I wrote about monitoring the total row counts and receiving email notifications when you get close that to nasty 10,000 or 10 mil mark.

Heroku Postgres Row Limit Email Notifications
Ever wished you could do multipass rendering with Mustache? Ever wonder why you might want to? Ever wondered how the heck Mustache works? Do I have the blog post for you!
I just launched Hakiri—a web app that gives you peace of mind about your web projects' security. Just select versions of technologies that you use in your projects and Hakiri will notify you via email when new vulnerabilities are discovered so you can update quickly.

Hakiri currently supports a limited set of technologies like Ruby/Rails, Postgres, Java, etc. I plan to add more soon.
I've just written how to increase confidence of isolated specs with Bogus.
Let's look at how to get visibility into an important component of any complex system: the messaging queue. Specifically, let’s look at how to trace a job from Rails using Resque. Read more here.
May 13, 2013
A different take on User Registration; one that keeps user registration out of the User class, the controller and implements it using a Form Object.
Us pirates don't like paying for things which is why we love Open Source software. But that doesn't mean we don't want to give back! With that in mind we'd like to give away 2 tickets for the next edition of ArrrrCamp in October. All you need to do is submit as many pull requests for open source projects as you want.
Compose and manage domain logic and data persistence separately and intelligently, Datamappify is loosely based on the Repository Pattern and Entity Aggregation.

Datamappify is built using Virtus and existing ORMs (ActiveRecord and Sequel, etc). The design goal is to utilise the powerfulness of existing ORMs as well as to separate domain logic (model behaviour) from data persistence.

Attributes lazy loading has just been implemented, check it out: https://github.com/fredwu/datamappify
Isn't Cloudinary great?  millwoodonline.co.uk
Since discovering Cloudinary I have have been finding handling images less of a chore. It takes out so much of the effort when dynamically resizing and cropping images. I put together a tutorial on how to use it. Uploading many images to Cloudinary with Carrierwave
Yandex::Webmaster gem and some bonus  igor-alexandrov.github.io
I just released Yandex::Webmaster. It is an API wrapper for Yandex.Webmaster tools. Now you can easily integrate information from Yandex into your Ruby application.

Read about it in my blog: http://igor-alexandrov.github.io/blog/2013/05/13/yandex-webmaster-gem-and-something-more/ and don't forget to find bonus at the of the post that will be interesting for developers from all over the world (not only those who use Yandex.Webmaster)
Yehuda Katz and Steve Klabnik recently released a work-in-progress draft of jsonapi.org which documents a particular format for creating consistent JSON API responses. This guide documents how to render resources properly along with associated relationships. In order to make following this guide easier when using rabl templating, I have published a conforming to jsonapi.org wiki page. Feel free to contribute to it as their guide is updated.
May 12, 2013
Find out how easy it is to roll your own authentication from scratch with Rails. A blog post for anybody that would like to know the basics of what goes behind an authentication system. I hope you find this useful!
Tabulous 2 is a complete rewrite of the tabulous gem that makes adding tabs to your Rails apps easier than ever.
Today I'd like to introduce a new tool to manage Git hooks. It's called Mestral and is available at GitHub.

It is written in Ruby and inspired by Homebrew). It uses Git itself to load and update hooks and aims to be easy to use for both users and hook authors.

Currently, it's an early proof of concept and I'm looking for some early adopters who want to try it, give valuable feedback and maybe contribute to the development. That means any feedback is appreciated, may it be a short tweet to @k0raktor, an issue on GitHub or a pull request.
May 11, 2013
I've just released RuboCop 0.7.0! Some of the highlights include 16 new checks, simplified configuration, the ability to exclude files/folders and the usual ton of bugfixes.
May 10, 2013
The last ticket batch for this year's EuRuKo is live at euruko2013 and it's on until the upcoming Monday at noon UTC. We are preparing a surprise for willing delegates which involves sailing and the deep blue Aegean sea. We'd love to see you in Athens this summer. Rock on!
Description of an obscure problem with Rails STI along with a solution.
Running a Minitest Suite  crashruby.com
An article exploring a few different ways to kick off a Minitest suite.
Short intro blog post. Project on GitHub.
Need a model diagram for your Rails project? I did and found a really easy way to do it using Rails ERD.
I just created gem for sharing content on social networking sites socialshare
Sinatra Vs Ruby on Rails  millwoodonline.co.uk
There often seems to be a lot of questions around which Ruby framework to use, Sinatra or Ruby on Rails? They are very, very different frameworks, and have different use cases. More info on the differences between Sinatra and Ruby on Rails.
attempt to make chef know remote branches  amolnpujari.wordpress.com
amolnpujari.wordpress.com/
May 09, 2013
ContextValidations  reefpoints.dockyard.com
An attempt to solve contextual validation problems in Rails
A few weeks ago, webserver request queueing came under heightened scrutiny as rapgenius blasted Heroku for not using as much autotune as promised in their “intelligent load balancing”. If you somehow missed the write-up (or response), check it out for its great simulations of load balancing strategies on Heroku.

What if you’re not running on Heroku? Well, the same wisdom still applies – know your application’s load balancing and concurrency and measure its performance. Let’s explore how request queueing affects applications in the non-PaaS world and what you can do about it. Read more here.
I wrote about what went down in Portland this year: RailsConf 2013 Review