1

I'm currently using Visual Studio 2010 and Visual Assist X to do rename refactorings in managed C++ code. For small codebases or renaming items which are not used very often in the code it works great.

It's almost impossible to rename an item which is used frequently in a large codebase because Visual Assist keeps every changed file open and unsaved. This means if there are a lot of files open the next file takes even longer to be opened.

Since I'm using version control this does not make sense to me because I could revert all the changes if something went wrong.

Is there a way to do that refactoring without keeping files open? Maybe also with another VS extension? I did not find any information about so far...

For example: I have a solution with about 100 projects, if I rename a class which is used frequently Visual Assist X's execution of renaming takes about 30 minutes or more. It opens every file which must be changed. As longer the renaming runs, the more files are open in VS and the more longer it takes to open another file...

Harry13
  • 733
  • 1
  • 4
  • 15

1 Answers1

0

At least there is a workaround.

When I have too many tabs open, I close them via Window / Windows ... and there Ctrl+A, de-selecting one or two needed windows and then "Close Window(s)".

Additionally I use File / Save All excessively. I have it mapped to Ctrl+Shift+S but I'm not sure if this is standard.

TobiMcNamobi
  • 4,687
  • 3
  • 33
  • 52
  • Do you do that while refactoring is in progress? Sure if refactoring is finished I do that as well but my problem is that refactoring does not finish or takes hours because there are too many files open and therefore opening another files takes even longer... – Harry13 Apr 17 '13 at 11:37
  • Yes, I do this anytime when I feel there are too many files open. When there is the need to re-open a closed file, in most cases I'm fine with the Goto command (Alt+G, thanks VAX). For everything else you may use the file search (Alt+Shift+O, thanks again VAX). But normally I'm working in one or two files and have an additional one or two files open for looking up things. Every other file can be closed. – TobiMcNamobi Apr 17 '13 at 13:10
  • I'm not sure if we talk about the same thing here: Are you closing files while Visual Assist X is executing the renaming? If I just work with VS then I know how to close any file I do not need ;-) For example: I have a solution with about 100 projects, if I rename a class which is used frequently Visual Assist X execution of renaming takes about 30 minutes or more and opens every file which must be changed. As longer the renaming runs the more files are open and the more longer it takes to open another file... – Harry13 Apr 17 '13 at 13:32
  • Ah, by "while refactoring is in progress" you mean VAX doing one refactoring step for you. OK, then no, I'm not doing anything during one such step. And, wow, a single Rename taking so long ... Is it an option to do this Rename with some other tool, e.g. VS built-in rename-in-files or Notepad++? – TobiMcNamobi Apr 17 '13 at 14:00
  • Not really because these options you mention are not typesafe – Harry13 Apr 17 '13 at 14:13