A Little About Me...

I am a professional web developer, currently living in Florida. I <3 my beautiful girlfriend Laurie. When I am not in front of a computer, I enjoy working on cars, Volkswagens to be specific. I am a dog lover, I have a black and tan min pin named Jet. Dunkin' Donuts Coffee helps me get shit done. I am also an avid craft beer drinker, and I prefer IPAs the hoppier the better. I like to take pictures too, although I don't have as much time to dedicate to it as I wish I did.

11 Aug 2013

The Ultimate Workflow iTerm2, Tmux, Tmuxinator, and Vim

Just wanted to write a quick post about my workflow. I have been using Tmux, iTerm2, and Vim for a good while now and I love it. Since switching from writing PHP to writing Ruby full time, I have been working on upgrading my tools so they are better suited for Ruby and for working on multiple projects. Tmux is great for multiple projects cause you can setup different sessions for working on different projects. You can attach and detach from these sessions quickly which makes switching between projects on the fly a breeze. Enter Tmuxinator. Tmuxinator makes setting up complex tmux sessions a snap. Tmuxinator allows you to have a yaml configuration file for each project. Once you have your configuration file setup you can just run mux project-name start and it will setup your Tmux session as for you based on your configuration file. When I have some more time I will post about actually setting up and configuring Tmuxinator.

07 Jul 2013

Switched My Private Repos From Github to Bitbucket

I recently switched jobs from writing PHP to writing Ruby. The shop I work for now uses Bitbucket because they allow unlimited private repos. This makes absolute sense for me. I have all kinds of projects I don’t want to share with the public that I would love to have backed up to a remote git host. Bitbucket allowing 5 users for free and unlimited repos had me sold. Moved all of my private repos over to Bitbucket and downgraded my Github account to a free account. I mean Github is a great service but paying for private repos for projects I have not worked on in forever just doesn’t make sense to me.

22 Mar 2013

Using Mechanical Keyboards Saved My Career

I work full time for a company during the day writing PHP. At night I am usually hacking on something in Ruby. As most of you know spending so much time on the computer is bad for you. We got Macbook Pros at my day job last year, within months of using the flat keybord day and night my hands and wrists hurt so bad I thought my career was going to be over. After trying many things including wrist braces, wrist rests, and exercises I read somewhere about mechanical switch keyboards and how much better they are for typing for long periods of time. I ordered one from NewEgg and started using it for all my typing. That combined with some wrist and hand exercises and here I am a year later still programming 16 or 17 hours a day sometimes with no pain what so ever. Everyone is like how can you spend $100+ dollars on a keyboard? I say when it comes to your health and career longevity, $100 is not even a concern. I now use a Mitas keyboard at home and a CoolerMaster at work. I will never use a cheap or flat key keyboard ever again.

07 Mar 2012

Custom sort names EXTJS 4 grids

I build grids all the time in EXTJS 4 and they are usually dealing with a ton of data so server side sorting is a must. EXTJS sends the header name of the grid column and and the sort direction to the server by default. That’s all fine and dandy but most of the time my column header names differ from the names I need to send to the server for proper sorting. So here is what I came up with.

First I add a config called customSort to my column configs. The customSort will be the value that is sent to the server when clicking the grid column header.

var gridColumns = [{
    text: 'Id',
    dataIndex: 'id',
    width: 75
    text: 'Queue Cat',
    dataIndex: 'queue_cat',
    width: 100,
    customSort: 'DocumentQueueCategory.name'
    text: 'Queued to Customer',
    dataIndex: 'queued_to_customer',
    flex: 1,
    customSort: 'User.lastname'
    text: 'Locked By',
    dataIndex: 'locked_by',
    width: 150,
    customSort: 'LockedBy.lastname'
    text: 'Last Act. Admin',
    dataIndex: 'last_activity_admin',
    width: 150,
    customSort: 'LastActAdmin.lastname'
    text: 'Created',
    dataIndex: 'created',
    width: 110,
    format: 'm/d/y g:i a',
    xtype: 'datecolumn'
    text: 'Modified',
    dataIndex: 'modified',
    width: 110,
    format: 'm/d/y g:i a',
    xtype: 'datecolumn'

Then in the store for my grid I add some code to the before load listener to check for a customSort param on each column. If the param is found the store will send the customSort value to the server, if no customSort value is found it will send the column header name as normal.

listeners: {
  beforeload: function (store, options) {
      var oldSortParam = store.sorters.items[0].property;
      for(var i=0; i < gridColumns.length; i++) {
        var currentCol = gridColumns[i];
        if(currentCol.sortable && currentCol.customSort && 
           currentCol.dataIndex == oldSortParam) {
             store.sorters.items[0].property =