3

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?

simendsjo
  • 4,739
  • 2
  • 25
  • 53

1 Answers1

2

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

Also see Resharper vs. CodeRush.

Community
  • 1
  • 1
Nate Pinchot
  • 3,288
  • 24
  • 35
  • 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 Jun 08 '10 at 18:26
  • 1
    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 Jun 08 '10 at 18:32
  • 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 Jun 08 '10 at 18:39
  • Didn't catch that last previous comment. Checked ReSharper again, and it seems they have some of these features. – simendsjo Jun 08 '10 at 18:40
  • No open source alternatives exist? – Nilzor Sep 27 '12 at 09:16