Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there a refactoring tool that works across solutions files?

All the refactoring tools for C# and VB.Net that I have seen only consider the source code in a single visual studio solution.

For better or worse, our large (many related programs) system is spread over many solution files, however:

  • All the code is below a single windows folder.
  • Our nAnt based build system, builds all files in a windows folder to produce a single dll (bit more complex then this but not important for this question).
  • Therefore ALL “.cs” and “.vb” files below the single root folder are part of the system.

So I am looking for refactoring and reverse engineering tools that take a single folder as input and act on all files below that folder.

(The tools may need some help to decide what “public” and “internal” means, however most of the time “internal” means “in the same code tree” when a “code tree” is a folder that contains code and any child folders.)


Now I am being greedy, I would like the tools to create a lot of all the refactorings that have been done and to be able to replay the refactorings. Then I could try out ideal and if they work, throw away my code, get the latest code, you do the refactorings and checkin the code before anyone else changes the files. (Likewise for when branches need merging)

like image 548
Ian Ringrose Avatar asked Feb 11 '10 08:02

Ian Ringrose


People also ask

Is ReSharper used for refactoring the code?

ReSharper provides an extensive set of automated solution-wide code refactorings that allow you to rename, move, and safely delete symbols; introduce and inline fields, variables, or parameters, and carry out many more transformations painlessly.

Does Vscode support refactoring?

Visual Studio Code supports refactoring operations (refactorings) such as Extract Method and Extract Variable to improve your code base from within your editor.

What is a refactoring tool?

Code refactoring is a controller technique or process of restructuring your code without changing its external behavior for easier maintenance, better readability, understanding, and extended support. The main purpose of refactoring is to fight technical debt.


1 Answers

In the past I have done what Pratik has suggested and pulled all projects into a single solution just for the purposes of refactoring. Then personally I would use Resharper every time.

like image 73
David Ward Avatar answered Oct 26 '22 02:10

David Ward