Announcing time warp ruby gem

When writing tests, it is often desirable to bend time to test limits and edges of the day. It is especially useful to warp time to test results across the timezones of the world. Manipulating time is also useful to assure a day of the week, month or year every time the test runs.

Some may say “Why not just mock Time#now?” I see the point, but I find mocking around with baseline Ruby classes to be asking for trouble. Eventually unusual behavior will rear its head and a day will be lost debugging tests - the most excruciating debugging one can be subjected to.

For all of your time manipulation needs, give time warp a try in gem or plugin form.

Filter unwanted tweets from your Twitter stream

Ever find yourself annoyed by frequent talk of elections, memes and kitty-cats on Twitter? I have created a user script to apply to your Twitter Fluid instance or Firefox Greasemonkey install to enable regex whitelists and blacklists for filtering out tweets in your Twitter stream.

With this script installed, you will see whitelist and blacklist entry fields at the bottom of your sidebar:

The filter only applies to twitter.com/home* URL’s, so you will always see the entirety of a user’s tweets when visiting her homepage or browsing elsewhere within Twitter. As long as cookies are retained, the filter will remember your selections. Change your selection and hit enter or click away from the field to see immediate updates to your Tweet filtering.

Go ahead and install it.

25+ celebrity Twitter users and their follow costs

Mashable recently published a list of celebrities using Twitter. Before you go out and start following your favorite Stargate Atlantis star, it’s best you take a look at his follow cost.

Actors

Musicians

Politicians

Techies

Writers

The follow cost team

Fading flash message

Rails apps love flash messages. Little notes providing information, confirmation or warnings to the user. Typically implemented in a partial like so:

<% if flash[:warning] -%>
   <div id=‘warning’><%= flash[:warning] -%></div>
<% end -%>
<% if flash[:notice] -%>
  <div id=‘notice’><%= flash[:notice] -%></div>
<% end -%>

There are many cases where the message does not need to stick around for long. Consider a page with lots of AJAX interactions. Perhaps the user sends a message, which causes a page reload with a flash confirmation note (e.g. “You’re message was sent.”). After this the user will remain on the page for a relatively long time, maybe inline editing some properties or settings with AJAX tools.

It sure would be nice if that flash message would fade into the sunset after a few seconds and give back its valuable real estate, yes? Especially without forcing every flash message to disappear like Bobby Fischer.

Ask and receive, my friends. Introducing the fading_flash_message method, to be added to your nearest ApplicationController:

def fading_flash_message(text, seconds=3)
  text +
    <<-EOJS
      <script type=‘text/javascript’>
        Event.observe(window, ‘load’,function() {
          setTimeout(function() {
            message_id = $(‘notice’) ? ‘notice’ : ‘warning’;
            new Effect.Fade(message_id);
          }, #{seconds*1000});
        }, false);
      </script>
    EOJS
end

Setting a fading flash message in your controller is simple:

flash[:notice] = fading_flash_message("Thank you for your message.", 5)

This is change we can believe in, my friends.

Announcing follow cost

Sometimes you run into a Twitterer who you feel pressured to follow. All of your (Twitter) friends are following her. She apparently has a lot to say. But how much?

Now you can find out the answer to that question. Luke Francl and I have built follow cost to help you gauge the pain your next follow will inflict on you. Luke provides more details at the Rail Spikes blog.

Luke and I had a great experience working on follow cost over the past couple weekends. We hope you enjoy it!

Update: follow cost went viral.

Barry Hess, a story of mistaken identity

My cohort, Shawn, and his wife are making their way through State by State. Currently they are learning about Arizona. I was able to contribute with a story of my extremely odd connection to a semi-famous Arizonian.

Security of Stuff

Over the past year and change, I have been asked frequently “how did you hook up with those guys.” Typically, the conversation becomes less about “those guys” and more about the scenario that made a 7-year code monkey, husband, and father of two choose to jump out of the comfort of corporate life.

book shelf project 1 ~ striatic {notes}
Photo by striatic

Accumulating debt in the form of a mortgage, a couple cars, and college loans is not something I take lightly. Yet I don’t have many regrets on this front. I love living in a house versus an apartment or a duplex. Where I live requires I have at least one car. And I have never really felt buyer’s remorse on the whole education thing.

To meet the budget restrictions necessary to leave my corporate job, it was all the other trappings that had to fall by the wayside. America has become such a consumerist country (RE: current economic events) and I was as caught up in the act of collecting Stuff as anyone. I loved scouring the ‘net for DVD discounts. I was all over anything perceived as a “can’t miss” deal. The side effect was that these collections were not only costing me money, but also time.

I could not get rolling down the hill toward career change until I eliminated most of these little drains on my existence. I had to stop visiting deal-hunter websites, stop buying marginally enjoyable films the moment they were released, and stop researching the latest and greatest in alluring audio equipment. Cable television no longer made sense. Like a prolific U-boat, television sunk my time with alarming consistency.

I also had to give up time- and money-consuming hobbies. When I considered the number of hobbies I dabbled in, I realized it was just too much. Each one sapped resources in its own way. Golf, for one, was a beast of a hobby. This was easier to give up than I expected, likely due to my similarly-timed lack of improvement. I was not mastering any of these hobbies, and many I carried on with simply because it was what I had always done.

Dropping all of these little drains played a vital role in getting me to where I am. I realized I truly could enjoy hacking. Hacking became not only my career, but also my passion and hobby. And over time I started being good at it again. Motivating!

I’ll admit I may have went too far with eliminating hobbies, or at least done a poor job planning to return to them. It would have been good to not only have an exit strategy, but also a return strategy for at least a couple of the hobbies. Now I’m finding it difficult to think beyond my all-consuming hacking hobby.

Losing those collecting habits has been mostly positive. The mental drain I feel now is about getting rid of the remnants of those collections. While I am never letting go of my childhood baseball card collection, I would love to pass on a vast majority of my DVD’s, video games and computer parts.

I eliminated almost half of my clothes closet recently. It was great to be able to slide hangers across the clothes rod again. But there are tons of other bits and pieces just laying around the house. If only I could find an effective strategy to extract all of this Stuff from my possesion. Kind of sounds like a new hobby.

I much prefer my current mental issues to my former ones, though. The steps needed to improve my relationship with Stuff are clearer than ever before.

Announcing Harvest Co-op

We at Harvest are proud to announce Harvest Co-op:

No, no, no. Not that kind of Co-op.

Our Co-op helps your team get down to business. Our Co-op helps team members understand what their colleagues are working on without needing to interrupt them. Our Co-op will also help your team have fun and pass around interesting notes and links without forcing distraction.

Please do sign up for our launch mailing list.

Security of group health insurance

Over the past year and change, I have been asked frequently “how did you hook up with those guys.” Typically, the conversation becomes less about “those guys” and more about the scenario that made a 7-year code monkey, husband, and father of two choose to jump out of the comfort of corporate life.

Billy Mays is pitching health insurance hahahaha!
Photo by Alcoholica

This past winter I approached another hurdle: group health insurance. I had already been working on my own for almost a year. My wife worked twenty hours each week, less for income and more for the group health insurance benefits she received. We had two children, and that health insurance kept us from even discussing reducing my wife’s work commitment.

Then I changed tactics and started looking at health insurance as a strict money problem. Even though this money problem was like a Porsche lease is a money problem, it did help to bring a dollar amount into the decision making process. I drew up budgets that included higher monthly premium payments and the assumption of paying a huge deductible.

The large insurance numbers were very foreign to me. Enter yet another risk-tolerance test. Insuring ourselves meant that our potential to save money was threatened. If we paid all of our deductible, not much would be left over. On the bright side, if my family had a healthy year we’d be able to save more than in past years.

The non-monetary benefits out weighed the cost of insuring ourselves. We each saw our stress levels plummet once my wife began working eight hours per month. The cost of individual health insurance is a very real hurdle. I found the idea of losing group health insurance to be a false road block.

I love you, Grandma