Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Visual Studio: How to arrange the projects inside solution explorer by dependency

Is there any way to manually arrange the projects inside solution explorer of VS 2010+ based on the dependency (dependent project on higher level) ?

like image 636
Alireza Avatar asked Mar 30 '13 05:03

Alireza


People also ask

Should you place solution and project in the same directory?

Creating a Solution NET will create a new solution with the same name as the project, placing the solution files in the same directory as the project. Although this works fine for small projects, it isn't well suited to more complex applications.


1 Answers

No, but when I have a solution with a lot of projects that I want to convey this build flow, I do something that may suit your needs.

Because the Solution Explorer sorts things alphabetically, I put projects into "Solution Folders". I put a prefix on each project folder. So, I might name a folder "A. Helper Assemblies". So, my solution looks like this:

Solution
   A. Helper Assemblies
      Project1.vsproj
      Project2.vsproj
   B. Core Assemblies
      ProjectX.vsproj
      ProjectY.vsproj
   C. UI Assemblies
      ProjectMoe.vsproj
      ProjectLarry.vsproj
      ProjectShemp.vsproj

This doesn't change any project dependencies, though. It's simply a manual effort to ensure that the project build order matches the folder structure.

For exact details on adding a Solution Folder, go here: http://msdn.microsoft.com/en-us/library/c6c756s6(v=vs.100).aspx

like image 164
Johnny Kauffman Avatar answered Oct 12 '22 02:10

Johnny Kauffman