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.
Ruby 2.2.3 Class Basics : Part 1
Ruby 2.2.3 methods such as alias, creating class dynamically, superclass, allocate and new methods. Watch it here
Gem Warrior - RubyGem text adventure
I created a text adventure as my first game, and decided to do it as a RubyGem. Here’s my final wrapup of the process.
Login as any user with any_login gem (Devise + now with Authlogic)
Hello, here is an updated version of any_login gem. Now you can quickly login as any user in system: https://github.com/igorkasyanchuk/any_login [more inside]
Bubble Sort Visual Demo
Watch it here
Folding Postgres Window Functions into Rails
Parker Selbert explains why Postgres window functions are helpful, how to implement them and use tests to drive a switch from pure Ruby to a window function.
Rails 4 - Sample API application
Here’s the code of a sample API built with Rails 4 and a web app consuming it.
Building encrypted chat service for iOS, Android and Ruby
Themis is a mobile-to-backend cryptographic services library, which has a wrapper in Ruby. We wrote a nice tutorial on armoring classical Mobile Websocket Example (a Ruby chat server with clients for iOS and Android) with Themis cryptography.
Instrumenting Your Cache With Notifications
An exploration of instrumentation in Rails, beyond raw metrics. Learn how to measure everything your cache is doing with ActiveSupport::Notifications.
Why you should upgrade Celluloid ASAP to 0.17.2 (or downgrade to 0.16.0)
Long story short, Celluloid versions 0.17+ have a memory leak. More info.
How to Create a Custom Enumerable
Ruby is a wonderfully flexible language. An example of this flexibility is in the ability to define a custom collection class that acts as an Enumerable object. In Ruby, a collection that acts as an Enumerable is basically a class which holds a list of objects and exposes helpful methods for iteration and collection. An example of this pattern built into Ruby is the Array class. Creating your own Enumerable is as simple as including a module and defining a few crucial methods.
Ruby 2.2.2 Array Basics : Part 11
Ruby 2.2.2 Array methods such as sort, take, take_while, uniq, transpose, to_h and transpose. Watch the video here.
Building a JSON API with Rails 5
Learn how to build a JSON API with Rails and take advantage of the rails-api gem, which, starting with Rails 5, now comes built in.
Lotus v0.5.0
Mailers, custom coercions, command / query separation, improvements RailsGirls Summer of Code & Hack day! [more inside]
Concurrency with Resque - hacking our way through
I’ve written a blog post on how we use Resque to easily parallelise the execution of certain parts of our applications.
RailsApps interview on Ruby Rogues
The backstory about recent changes to the RailsApps project in an interview on the Ruby Rogues podcast.
A Small Case Study in Threading
Chuck Remes saves almost 10 days in a production import job by using real threads on Rubinius.
The Unix Log - Another RubyFlow Inspired Community LinkLog
I love RubyFlow and JSLive but I needed a site to post my unix related articles on. So I built The Unix Log. Please take a look and feel free to post anything unix, linux, or osx related to the site. Help me make this site as great as RubyFlow! http://theunixlog.com/
Using Pundit, The Cool Kid of Authorization
Authorization can often be one of the toughest parts of the development process. There are a few different ways to go about creating an authorization system, and there are a few different gems to choose from. This
blog post walks through using the pundit gem, including how to implement policies and scopes.
Internal vs External quality of software
Tips for maintaining the quality of your application, both from a developer’s point of view, and that of the end user.
Free O'Reilly E-Book(let) Download - Static Site Generators (Jekyll and Friends)
Hello, found via Vienna.html - covers Jekyll news - that O’Reilly offers a free E-Book(let) download (email required) for Static Site Generators: Modern Tools for Static Website Development by Brian Rinaldi (50+ pages). Looks at Jekyll (Ruby), Wintersmith (CoffeeScript/JavaScript) and Hugo (Go). Cheers. PS: The author Brian Rinaldi also has a great “Getting Started w/ Jekyll” article and a static site samples repo (for comparing Jekyll, Hugo and friends. What static site generator are you using? Let us know. Cheers.
Ruby 2.2.2 Array Basics : Part 10
Ruby 2.2.2 Array methods such as repeated_permutation, replace, reverse, reverse_each, rindex, rotate, sample, select, shift and shuffle. Watch the video here.
REST Fest 2015, links round up
SmartLogic developer Eric Oestrich went to Greenville, SC for REST Fest 2015. If you missed the weekend or want to catch up on resources you heard about, Eric has you covered with 30 links. [more inside]
Plain Ruby for generating primitive data structures from object graphs (ruby & rails)
Serial is a light-weight and simple serialization library which helps with serializing your models. It has a very small API surface, and is designed to be easy to reason about. It’s available on GitHub: github.com/elabs/serial
RailsStuff gem
RailsStuff is a collection of small useful modules for Rails apps. There is post with overview of one its features.