Archive

Archive for January, 2009

Efficient TextMate Project Panels

January 23rd, 2009

I ran into an issue with TextMate recently: the Find in Project function (command-shift-F) was taking over a minute to run and consuming huge amounts of memory in the process.

Before you scold me, know that I’m already using the time-honored tradition of excluding bloated directories like vendor/rails, log, doc, etc. using a bash alias.

This time, the culprit turned out to be my public/uploads folder which apparently included some documents that TextMate didn’t like to search.

Solution
Exclude the entire public directory from my alias and only include the javascripts and stylesheets directories. This has the added benefit of making my TextMate project panel easier to work with. After a little more thought, I decided I could do without the apps directory as well. The new look:

My TextMate Project Panel

My TextMate Project Panel

The alias:
alias rtm=’mate app/controllers app/helpers app/models app/views config lib db public/javascripts public/stylesheets spec stories vendor/plugins &’

And, when I want to have access to the excluded directories:
alias rtma=’mate . &’

TextMate colored labels provided by the ProjectPlus plugin.

Rails, TextMate

Stashing Git

January 21st, 2009

With any application, it’s tempting to learn only the commands you need for your daily tasks. The danger is that oftentimes, you miss one. You end up going the long way around a problem when there’s been a shortcut in existence all along.

I just learned a new git command (thank you, Michael Ivey) - git stash.

Some Background
On my primary Rails project, I’m the sole developer. Most times, I work from the master branch, but occasionally I’m working on a large feature that might take a week or more to complete. During those times, I want to maintain access to the master branch in case any bugs arise. So typically, I create a branch for the new feature and merge it in when the feature is complete.

Stashing
Stashing allows you to essentially put your most recent, uncommitted changes on hold while you make a small fix.

$ git stash => saves current changes for a later date
Make small fixes, commit, push, deploy, etc.
$ git stash apply => restore changes from saved state

Who knows if I’ll use this feature for anything more than the occasional quick fix, but it’s a good one to know about. Creating a branch for larger features still makes sense…mostly because I will do several commits to that branch before merging it back.

I don’t know how I would feel about doing EVERYTHING in the master branch, but this is a neat trick to have in my back pocket.

Git

Welcome

January 18th, 2009

Welcome to the original home (and the very first post) of the Atmospheric Labs blog.

At this point, Atmospheric Labs is a one-man web development shop that specializes in Ruby on Rails development. We (I) have also done projects in PHP, Python, Java, and some truly antiquated languages like Perl and Cold Fusion. There’s nothing wrong with those languages, but I’m a Ruby guy now and I’m looking to keep it that way - until, a cooler, more enjoyable language comes along. But for now, that’s a hard thing to imagine.

Over time, this site will grow and evolve, but I plan to keep my focus the same - developing easy-to-use web applications that don’t suck. Who’s to say what categories this blog will cover, but I’m on a UI kick right now so, we’ll probably start there. One thing is for sure, it’s going to be fairly technical. If you’re looking to follow my personal life, there’s always Facebook, email, or some good, old-fashioned face time.

Onwards!

General