Thursday, November 19, 2009

How to be Humble

I installed the new Rails Best Practices gem today, and I have to admit it kind of kicked me in the fork. In a good way.

Sometimes it's good to be reminded of just how many things you've done wrong, as it can really motivate you to dig in and get some of that stuff fixed. As for me and my statup's codebase? I have 291 violations of the best practices that need to be addressed. Oh well, at least I've moved from blissful ignorance to gut-wrenching enlightenment.

Want to get schooled on your own code base? Need a good swift kick yourself? Follow these steps:

1) Install ruby_best_practices
sudo gem install rails_best_practices --source

2) cd to your root directory of your rails project

3) execute this line:
rails_best_practices . --debug
(I used the debug flag because it tells you what file was just examined, that way if there's an explosive error and the process bombs, you'll know which file to investigate).

Happy self-humbling!

No comments: