Environment variables as a configuration means are everywhere in Ruby. For instance, ActiveRecord will use the single DATABASE_URL
environment variable for every part of it's configuration, no database.yml needed! If you are not on board with environment
variables, check out The Twelve-Factor App for configuration. This is exactly how good software platforms like Heroku work, all through
environment variables. But using environment variables in a Rails application can be tricky. During local development, you may not want
to set everything...
IT'S DANGEROUS TO GO ALONE! TAKE THIS! Our t-shirt fund-raiser on Booster.com only has a few days left. Don't miss out on this
8-bit-tacular Ruby shirt! Available in men, ladies & youth sizes! Last week, our localy Ruby community in Norfolk, VA re-launched
the 757rb.org website. This was the third static website I have build using Jekyll and the second since the official v1.0.0 release. It
was also completely different than any creative approach I have taken on. Please, go...
Kenneth Earle Collins, 66, of Chesapeake, Virginia, passed away January 5th, 2013. My father, known to his friends and family as Kenny,
was born in Logan, West Virginia and was the son of the late Edgar and Frances Collins. He was a retired Master Deputy with the
Chesapeake Sheriff's Department. Kenny is survived by his beloved wife of 7 years, Lois V. Collins; a sister, Lanna DeVites and
husband John of Zuni, VA; 4 sons, Benjamin M. Collins and fiancée...
The latest README for HolyGrailHarness will always be on the Github project page. A curated Rails application prototype that focuses on
like Rails Composer, the HolyGrailHarness is a basic Rails application that can be considered a prototype and customized via a simple
setup script. It is also somewhat opinionated in that it promotes simple and powerful testing choices and focuses on using...
Any good Ruby developer that tests time-dependent code has used the Timecop gem. Timecop provides dead simple time travel and freezing
something like a Rails application and you want to alter the test browser's clock as well? The answer is pretty simple, but let's first
examine all the parts at play here. Rails & Capybara My examples leverage...
the Moment.js JavaScrpt date library! Moment.js has a very rich API for parsing and working with times, very similiar to
ActiveSupport's extensions. However, it does not have a solid way of moving times across zones. Especially if those zones may or may
interpret MVC differently. These differences are an academic rabbit hole and if you are really interested about them, I recommend
reading some of the resource links at the bottom of this post. One in particular by Jonas Nicklas really outlined how I think client
When ActiveRecord 3.2 was released there was a small addition called ActiveRecord::Store which bills itself as a simple key/value store
for your models. The code below is pulled right from their example usage. class User < ActiveRecord::Base store :settings,
accessors: [:color, :homepage] end @user = User.new(color: 'black', homepage: '37signals.com') @user.color # =>
'black' @user.settings[:color] # => 'black' @user.settings[:remember_me] = true Most people know that I love simple
tools. But when I found myself considering ActiveRecord::Store, I found it seriously lacking...
Previously I had updated this article to say that this commit looked like it gives you real variable properties in LESS. I was wrong!
So even in LESS v1.3 you are still screwed for doing metaprogramming and working with a real CSS preprocessor. That may change for LESS
v1.4 and if you want to help make that happen. I suggst you put your weight behind this github pull request. First, a little bit of
background. A while back ago I...
OK I know I promised that we would start the dive into testing your Spine.JS application using Jasmine(rice) in my last article, but
this is a good diversion. If you are new to my latest series on Spine.JS and Jasmine, scroll on down to the bottom to the related
section and read back. However, for those that might be more familiar with Jasmine and specifically Guard::Jasmine and ever felt the
pain that debugging from that terminal window was lacking, read...
So this is the third part to my mini series on Rails and Spine.JS. Part one covers an initial setup and how to include Spine.JS into
your Rails project while part two is actually the first of a tome on how to test your Spine.JS application. Assuming you have covered
the bases there, lets get right down to business and review some of the elegant hacks ™ yours truly came up with while testing my
own Spine.jS application using Guard...
In my previous article I talked a little bit about why I decided to use Spine.JS and how to include the CoffeeScript source into your
Rails project using git submodules. Now I would like to talk about testing your brand new Spine.JS application. Afterward, be sure to
application, HomeMarks, I decided to learn Backbone.js. Thankfully a local friend of mine recommended that I try Spine.JS. I was
immediately hooked! Why Spine.JS? Spine.JS is is authored in CoffeeScript and that is a big deal for me. I will never write raw
This weekend I decided to experiment with LESS CSS by replacing the existing Sass and Compass code that had been built thus far a small
project. Why? Three basic reasons. First, I wanted to see how LESS stacked up. Second, I was intrigued by some of LESS' features, in
particular their namespace support. Lastly, I wanted to use Twitter's Bootstrap project as a baseline for my design. Since Rails 3.1
has been out for some time, I was expecting the...
One part of Objective-C that I like is being able to send messages to nil objects safely and more so their KVC and KVO patterns. In
Ruby I often use the #try method to safely send messages to objects that may be nil at runtime. But one thing I always wanted was a
nice way to send a key path, basically a string of methods signatures, to an object in the same way. I give you my simple #try_keypath