Rack is probably the coolest web-development thing to come out of the Ruby community in the 5-ish years I’ve been paying attention. I’m continually impressed with projects like this :).
For reasons relating to rvm and TextMate’s continual inability to cope with it (seriously, where is TM2? ;) ), I’ve been running specs from the command line pretty much exclusively these days. Telling rspec to just run one suite at a time isn’t a particular problem, but what if you want to focus on a tighter set: one description block, or tighter still, one spec at a time? Or how about if you want to mark a set of specs that define a cross-cutting set of concerns and run those all?
Well, turns out you can pretty easily specify a line number (in both rspec 1 and 2) to run, and with rspec 2 you can tag specs and run only the tagged tests pretty easily as well. I’ve made a gist of here (hopefully embedded below) for future reference. Super-handy. Stay on target!
This is yet another awesome project from Bryan Helmkamp. This is rack middleware that adds a diagnostic toolbar to your web app. Usage is as simple as config.middleware.use “Rack::Bug”
Though I missed some sessions and social activities due to all-consuming fatigue and flu symptoms, I enjoyed my Rubyconf X-treme X-perience*. Here’s what I thought particularly stood out:
On a professional “developing my craft” level:
- @tenderlove’s talk, “ZOMG WHY IS THIS CODE SO SLOW” was a great—and well presented—overview of how to break down a complex system and rebuild it in a clean, performant manner. The talk shifted back and forth between some clearly developed principles and Aaron’s actual work rebuilding ARel for performance reasons.
- The twin pairing of Shugo Maeda’s talk on Refinements and Classboxes with @yukihiro_matz’s keynote on Ruby 2 and Rite. Rite is an configurable, embedded flavor of the Ruby VM that is targeting gadgets and household appliances. Ruby 2 will preserve all the “Ruby is for consenting adults” power and expressivity of the language but will provide tools to keep things clean (Refinements and method wrapping).
On a personal “this is really awesome must play with it” level:
- @merbist’s update on what MacRuby has been up to and where it is at… and where it could go. I haven’t really had the time to check in on MacRuby in awhile so it was awesome to see the progress they’ve made since last year. It’s got a kick-ass GC, has native Grand Central Dispatch support, supports pretty much all the Cocoa stuff, etc etc. With Apple backing MacRuby and recently pitching Java over the side… I wonder. You can’t target iOS right now (no GC), but Matt Aimonetti coyly told the audience that it “would be possible without a huge effort” to get there. Hmmmm.
On a philosophical “I wonder if other conferences have these sort of talks” level:
- Dave Thomas’ keynote and challenges to the community. Documented here earlier.
- @dhh’s idiosyncratic and foul-mouthed rambling walk through politics, aesthetics, and philosophy titled “Why Ruby?”: his message about personal freedom and responsibility in a programming context paired nicely with a bunch of my recent reading material and the TSA-related horrorshow that cropped up shortly before the conference opened.
And, finally, New Orleans, and the New Orleans ruby community, some of which I got to experience, but not half so much as I wanted to and certainly less than half as fully as they deserved. Job well done as hosts.** Bonus points for my cab driver on the way out who, upon learning I was from Michigan, launched into a more optimistic defense and projection for the auto industry than I would have suspected possible outside Michigan. I had to council lowered expectations! He loves his chevy, though, so that’s something Detroit’s got in its corner that I bet it doesn’t know about: New Orleans-based immigrant cab drivers from the middle east.
(* with apologies to @tenderlove for stealing his joke.)
(** New Orleans felt a lot like a warmer version of Detroit that everyone still likes to visit: old, gorgeous but rundown buildings, tons of vacant lots and breaking down buildings, some new development, but yet nobody seemed intimidated or frightened by it. Southern hospitality? Lack of bad press? Who knows.)
— @tenderlove, from his excellent Rubyconf X presentation “ZOMG Why is this code so slow?” (Hopefully there will be a video. Slides don’t do it justice.)
@pragdave kicked off RubyConf X this morning with a typically quirky history of Ruby’s last ten years, before launching in to the meat of the matter. Now that we’ve had ten years under our belts and moved from a niche-lovers niche to nearly mainstream, what next? He issued three challenges that I think are worth repeating:
- Find someone to inspire who isn’t like you. Get more women involved. Change Hacker culture to no longer subconsciously exclude and intimidate women. Teach kids. Fewer and fewer americans are going into software development, and fewer and fewer of those are women. Women are 47% of the workforce, but only 25% of math/cs, 5.6% of the ruby subgroup, and 1.5% of the F/OSS metagroup. Ouch. And seriously: teach some kids. It’s rewarding!
- Diversify our experience. Not group-level diversity; individual-level diversity. Stop identifying yourself as a monolinguist: “I’m a java programmer / I’m a ruby programmer.” Monolingual people are arrogant to the point of ignorance. Monolingual people are maintenance programmers. Push yourself to learn. Pick a new language or study a classic. Try non-OO programming. Move outside comfort zones.
- Get out of the rut. Ruby is in danger of becoming a suburb; are rubyists actually becoming judgmental and ceremonious? It seems like new projects require all kinds of ceremonial gem installation and configuration. What’s with that? Too many really smart people making incremental advancements to someone else’s stuff. Instead of saying “I could do that better”, start doing something new. Cultivate a Pioneer mentality. Do it first, even if it is the worst.
I detected some skepticism from the grouping around me, but I think these are valuable and admirable goals to have in mind as we create our future, both as hackers and as a community organized around ruby.
Bonus self-congratulatory wankery: I am consistently impressed that rubyists in general constantly explore other languages and other paradigms. It says something positive that such experimentation outside the “walls” is not only condoned but praised and encouraged. Maybe we do need to do a better job bringing what we learn back and interfacing in a positive way, but suburbanites don’t normally like to explore. There’s hope for the future, there.
Sinatra is awesome, mongoDB is fun and easy, and bundler is the new hotness, but I got tired of laying the plumbing necessary to get these (and rspec) up and running over and over, so I forked a popular application template and started to customize it.
It’s here on the github. More and better goodies await, too! Like jQuery. And Cucumber.
Hopefully soon I’ll put something together to demo it.
— Brandon Bloom, as the conclusion of an nice story of two pythonistas discovering rails. One word of caution though: sometimes “Black Magic” backfires spectacularly.
(Source: blog.brandonbloom.name)