Links of the Week [08/22/2010]

August 22nd, 2010

WhyDay

August 19th, 2010

Anyone in the Ruby community probably knows about Why The Lucky Stiff and his numerous contributions to Ruby and the Ruby community[0].  They’ll also know that a while back _Why decided to disappear, removing his code, sites, and closing down his various accounts.  In celebration of what he brought to us Today, August 19th is Why Day, in which people are encouraged to:

  • See how far you can push some weird corner of Ruby (or some other language).
  • Try that wild idea you’ve been sitting on because it’s too crazy.
  • or others….

One thing I know you can do is to use Skype to call “coderpath” and leave a message about what you think of _Why and Why Day.   Call coderpath’s skype (you of course need Skype installed and a Skype account…).

If you’re looking for a reminder of what _Why brought to the community, you can check out whymirror on github, where most of _Why’s various projects have been restored and preserved.  Most special though (in my opinion anyway) are:

Using VIM In Your Workflow

August 3rd, 2010

After a bit of a wait, my buddy Curtis McHale has posted the article I wrote for his site, yourworkflow.ca.  You can check out the Using Vim As A Text Editor article over on the site.  It’s not just about Vim, but more the day to day coding workflow that I was using, so it includes things like Firefox plugins, Unix utilities, etc.

So head over and check out the workflow site and read not only my fine fine article, but also the other news and podcasts he’s got going on over there.

Rails Tutorial Updated To Rails 3.0

July 28th, 2010

Huge congrats go out to Michael Hartl for upgrading his awesome RailsTutorial.org for Rails 3.0.  Now you have the choice of reading the 2.x version or the 3.0 version of the site.  Many thanks go to Michael for his hard work and huge contribution to the Ruby and Rails community!

Thinking on The New Paradigm Of Web Application Development

July 26th, 2010

This is probably old news to everyone who reads this, but today I had a bit of an epiphany.  I was watching Charles Max Wood’s excellent Teach Me To Code Screen-cast and realized (after watching two parts of his “building a blog” series) that he wasn’t ever actually looking at the output of his coding, at least in the traditional sense.

The way I’ve coded since, well, forever has been like this.  I open up my editor window, and an output window.  When I was writing C code back in the dot com days this was another terminal with a “make && ./app” in it, and in my newer web application days, a browser window with my mouse hand on the reload button. After a bit of code was written, I’d either hit “up-arrow enter” for C code or reload the browser, and see what’s happened.

Watching the screen-cast I realize that Charles was doing the following (as far as I can tell, as I’m pretty new to the whole TDD thing):

  • Writing a scenario or feature (using cucumber)
  • Using that to generate tests (with rspec, I think)
  • Running the test, watching it fail
  • Writing the code to make the test pass
  • Running the test, watching it pass
  • Repeat…

Now the last four steps I do know about, those are standard TDD methodology, broken down into Red (write a failing test), Green (make it pass), Refactor (make the code better), but I was blown away with the realization that he wasn’t looking at the output of the code he was writing, but instead was letting the testing framework do the work, so instead of having to verify with your own eyes that the [insert web page you're interested in here] is showing properly, you have it checked programmatically, no browser needed (in fact, at the point in part two when the browser is needed, there’s that uncomfortable pause while FireFox groans and raises itself into a running state).

Is that what TDD is really about?  I’ve always imagined it as an augmentation to the previously-described way I used to code in that before I coded and reloaded the browser window you’d write the test, then the code, then the browser reload, then the test again to make sure it passed.

This is a whole new world that’s frankly thrown me for a loop, and into a fervor of reading up on cucumber.  I’m not sure how this will affect my code writing, but this makes the whole world of TDD a lot more interesting!  Course, I’ll have to re-watch the two episodes to make sure I truly grok the tools that he’s using.

Further Reading / Links

DataMapper 1.0 Interview

July 21st, 2010

My buddy Dan Kubb has a nice interview on the recent DataMapper 1.0 Milestone.  DM is something that I have been wanting to look at forever, everytime Dan does his “let me just show you how to do this in DM instead of ActiveRecord” stints, I’m always amazed at how fast and easy he does things.  Of course, I’m also amazed at how fast and easy things are done in ActiveRecord by people who are proficient in it :)  Time to break out the Rails 3 and see how fast and easy the integration of DM into it is!

Anyway, a great interview and well worth the read.