I totally read it on Some Guy’s Blog

It must be true!

Archive for November, 2008

What’s Now In Rails: Libraries

without comments

What Gems/Jimmies are you finding indispensable these days?

@peter_braswell

Dr. Nic’s Textmate Footnotes

Famous Railsist “Dr. Nic” has a great footnotes plugin which you can get a taste for from the README on that page. It’s a must install if you choose TextMate as your editor.

Named scopes

Your Rails developer badge will shortly be revoked if you do not learn and use named scopes liberally. The way that they can be named, composed, and reused in multiple contexts can result in some extremely powerful and expressive code, that remains readable and even has some excellent performance characteristics.

Learn more at RailsCasts and Ryan’s blog

will_paginate

Out of the box Rails pagination is a thing of the past, I think. will_paginate is as much of a drop in as it gets, and it’s flexible in all the right ways. It’s also kept very much up to date and remains in active development.

rSpec and cucumber

While I’ve decided that my overall thoughts on testing are probably going to end up being a talk, I can provide my favorites here. rSpec provides a nicer syntax than test/unit for my tastes. Further, the capabilities that come with the stories functionality provided by cucumber (detailed by Peepcode) have been a revelation on my primary project.

fixture_replacement2

I personally have come to dislike fixtures strongly. There are definitely techniques that can be used to reduce their downsides, like dataset (previously known as scenarios), but I favor leaving them behind altogether. Once you’ve made that decision, you have options still, like factory-girl (plenty of good alternatives mentioned at that link, as well). dataset even mentions that it can play along with other alternatives

For my part, I’m satisfied with fixture_replacement which is in a second version. It doesn’t look like it’s active, but I enjoy the flexibility that comes with being able to ask easily for objects that have or have not been persisted and they have the exact same set-up. I hope to provide more detail there later.

These are the only tips and techniques that I’d bring onto each project. For anything else, I’d be checking out the diverse Rails ecosystem out there! It’s getting more pleasant by the week.

Written by bigfleet

November 24th, 2008 at 1:20 am

Posted in Uncategorized

What’s Now In Rails: Information for the Beginner

with 5 comments

The Question

What the latest/greatest sources of information/tutorials/gadgets for RoR is. Sure I can Google, but I’d like to get recommendations from the source. Maybe you have Delicious tags, dunno?

@peter_braswell

Twitter

The Rails community does actually say what they’re up to. The RubyLearning blog recently complied a list of the top Rubyist Twitter personalities. This is a good way to be on the cutting edge without actually doing anything. It can also help you engage directly with those who can help the most.

The Aggregators

Peter Cooper (@peterc) runs Ruby Inside and Rails Inside which aggregate and comment on a lot of what’s happening in the community. Follow those and start from there to build a respectable blog roll.

Rails Core

Recently the official Rails blog has really stepped forward, but in quantity and quality of posts. It’s also, of course, a canonical source for information. Gregg Pollack’s “This Week in Rails” posts are a highlight, of course along with the original ‘What’s New in Edge Rails’ series from a core contributor.

Themes in Modern Rails

Bootstrapping

A lot of successful companies that are using Rails have arrived at their success through a consultancy approach that focuses on green-field applications. While Rails certainly can be used with legacy applications, it’s not really a secret that writing new applications is the bread and butter for Rails. As a result, more and more bootstrapping supplements are available at the beginning of projects. These have an aim of providing useful tools, or adding a few additional opinions to add to the pile of opinions Rails has about how you ought to be writing your apps.

My understanding is that Bort was one of the elements allowed during the recent Rails Rumble. thoughtbot, a respected consultancy that is absolutely killing it with their open source contributions, offers suspenders, which they use at the beginning of all their projects. Others are also available, but these seem of particular importance.

I personally have never used any of them, because I seemingly never start new projects. They certainly may be of interest to those at the “Hello World” level today.

Git and GitHub

If any method for hosting your source code were ever to be compared to Studio 54, GitHub would have to be it. The process of hosting, contributing, documenting, and using drugs open source has never been easier. It’s en vogue among Rubyists and you and your projects will be better of by learning and using Git. (Protips available from PeepCode, an outstanding source for info in its own right.)

Git is a complete re-imagining of source control. It’s not like the transition from CVS to SVN. There are a lot more concepts to learn, and with more power comes more responsibility. As my familiarity with git has grown, I am sure that I will never go back to Subversion.

The fact that GitHub is so popular, with such an incredibly active and present ecosystem of open-source tools is just another layer of awesome on top. It looks like it might have been Josh Susser who said that “GitHub is social networking for geeks.”

RailsCasts

In addition to the aforementioned PeepCode, there are a few additional sources for screencasts. I personally have most of those screencasts, and have never been disappointed.

The Pragmatic Programmers screencasts and the EnvyCast series are also good.

Although they deal with topics that aren’t always for beginners, the RailsCasts series is not to be missed. Ryan Bates does a great job with consistently turning out quality work, and RailsCasts are free.

Delicious

I do occasionally tag Rails and Ruby items of interest to me. YMMV.

Written by bigfleet

November 7th, 2008 at 9:30 pm

Posted in Uncategorized