Browsing All Posts filed under »refactoring«

interviewed at scottish ruby conf

November 10, 2010

0

Way back in March of this year, while I was attending the Scottish Ruby Conference, Werner Schuster interviewed me for InfoQ. The video has been online since August, and this is me finally getting around to telling you about it; watch it here. I talk about Reek, Refactoring in Ruby, and agile development in general.… [Read more…]

interviewed on railscoach

May 13, 2010

0

Charles Max Wood has just posted an interview he did with me a couple of weeks back. It’s about Reek, Refactoring in Ruby and agile development practices. I waffle too much, and make a couple of historical mistakes. Ho hum.

extract class or substitute algorithm?

January 31, 2010

3

I have a dilemma. In fact, I frequently have this dilemma, so I thought I’d ask your opinion on which way you would address it. I just completed a CRC session for the next feature I want to add to my codebase. One of the classes identified for the new scenarios is a particular kind… [Read more…]

fixing Feature Envy by backtracking

January 15, 2010

1

After a conversation this week with Hugh Sasse about Feature Envy and Utility Functions, I realised I’ve evolved my approach to dealing with them: When Reek tells me about one of these smells, my first step is to inline the smelly method back into all of its callers. Then I look for ways to fix… [Read more…]

devver are using reek

October 28, 2009

0

Interesting link: In Improving Code using Metric Fu the folks at devver.net give a little insight into how they have been using Reek and the other Ruby quality tools to improve their codebase.

reflections on shotgun surgery

July 24, 2009

9

I’ve just finished refactoring the code of Reek to (almost) eliminate a large dose of Shotgun Surgery, so I thought the time was ripe for a little reflection on what occurred and why. What is Shotgun Surgery? This is a code smell that occurs when you have to change loads of existing code in order… [Read more…]

factory method in ruby

July 14, 2009

8

During my refactoring homework last evening I noticed a little tug-of-war between two different coding styles, and after a restless night I’ll try to analyse here what was going on… Deep inside Reek is a Source class, whose instances are responsible for converting Ruby code into abstract syntax trees for later examination by the various… [Read more…]

the “anchor adapter”

January 22, 2009

6

Warning: academic theorizing and hypothesizing follow. Oh, and half-baked pontification. I just finished refactoring reek to drive in a major new chunk of functionality (configuration files) which I’ll release soon, when I’ve had time for some thorough testing. The refactoring needed to accommodate the change was huge, occupying much of my free time over the… [Read more…]

too much TemplateMethod

January 4, 2009

2

I’ve been refactoring a lot during the festive break, and I’ve noticed that in many cases it was more difficult than I would have liked. Today I think I figured out the reason for that: I use the TemplateMethod pattern too much. When I see a duplicated algorithm, it seems that my natural tendency is… [Read more…]

primitive obsession in ruby

December 2, 2008

2

I spent an hour or so this afternoon refactoring some code deep inside reek. I wanted to simplify the code that checks for the Uncommunicative Name smell, but it just wouldn’t fall out as clean as I would like. And at some points it seemed that I was going around in circles — a name… [Read more…]

Follow

Get every new post delivered to your Inbox.

Join 667 other followers