views:

63

answers:

1

When I hack around, some code tend to get much bigger than originally planned. As this happens I usually introduce/collapse/merge namespaces, move files between them, move folders etc etc. Sometimes, if I don't have a clear picture of the end result, this is a real pain and really easy to just "skip". This leads the project deteriorate where classes belong elsewhere, strange namespaces, no folders/wrong folders etc. And then I usually cannot take it anymore and do a larger cleanup - which is usually not difficult, just very tedious and it feels nice to do everything at once, so I do a code freeze while finishing up.

So my question is... Are there any tools to help refactoring the namespace/physical aspects of a project?

+1  A: 

Most popular refactoring tools for Visual Studio are Resharper and Code Rush.

Also see Resharper vs. CodeRush.

Nate Pinchot
I've had good experiences using the Resharper tools for changing namespaces and folders. It cleanly updates dependencies across all projects in the solution.
Dan Bryant
I'm using CodeRush already and love it. But still, I'm missing some refactoring - unless I'm overlooking something. Just a couple of things would help a lot: * Move class to namespace * Rename namespace
simendsjo
I am not extremely versed in CodeRush, but it is possible to rename a namespace with Resharper (I just tried it and had no issues).
Nate Pinchot
Didn't catch that last previous comment. Checked ReSharper again, and it seems they have some of these features.
simendsjo