Unloading different sets of projects in Visual Studio

[亡魂溺海] 提交于 2019-12-22 06:45:04

问题


Is there an extension to Visual Studio that provides the ability to create something like an 'unloaded project profile' for a solution?

I have a solution with a large number of projects (~100). When working on a certain part, I can unload unrelated projects to improve performance. I'd like to be able to save this group of unloaded projects, so that when I switch to working on a different part I can then cause it's projects to be loaded instead.


回答1:


I ended up writing my own extension to do this - Loaded Projects, for Visual Studio 2012.

But then I discovered Funnel (by Dimitri Dering), which takes the same concept to the next level, with a more polished UI and additional features.




回答2:


This guy recommends comparmentalizing projects into "Solution Folders" so you can right-click and load/unload all of the projects in a given solution folder:

http://blogs.msdn.com/b/jjameson/archive/2009/03/06/large-visual-studio-solutions-by-loading-unloading-projects.aspx

He also shows how you can write macros to load or unload groups of projects:

http://blogs.msdn.com/b/jjameson/archive/2009/03/11/visual-studio-macros-for-unloading-reloading-projects.aspx




回答3:


Visual Studio 2019 has a new concept called "Solution Filter Files".

https://docs.microsoft.com/en-us/visualstudio/ide/filtered-solutions?view=vs-2019

You can right click on a solution after you've unloaded what you want and do "Save as solution filter". It creates a file which is a list of projects to INCLUDE in opening. So if a new project is added, I don't think it would be picked up.

Another important feature to note is the right click "Show unloaded projects" and the right click "Hide unloaded projects".

FYI - The file looks like this:

{
  "solution": {
    "path": "IvaraDotNet.sln",
    "projects": [
      "AssetManagement\\StaticLoad\\AssetManagementStaticLoad.vcxproj",
       ....
      "framework\\oqpersman\\oqpersman.vcxproj"
    ]
  }
}


来源:https://stackoverflow.com/questions/15261245/unloading-different-sets-of-projects-in-visual-studio

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!