Skip to content
Browse files

[Assets] Order windows executable project first in solution files (sl…

…n) so that VS uses them as startup project by default
  • Loading branch information
xen2 committed Nov 21, 2018
1 parent 15ea506 commit b226444233e0fefec0e8868967e5d1ab4b2f27a4
Showing with 7 additions and 1 deletion.
  1. +7 −1 sources/assets/Xenko.Core.Assets/PackageSession.cs
@@ -1194,7 +1194,13 @@ private void RegisterProject(PackageContainer project)
// Note: when loading, package might already be there
// TODO CSPROJ=XKPKG: skip it in a proper way? (context info)
if (!VSSolution.Projects.Contains(solutionProject.VSProject))
// Special case: let's put executable windows project first, so that Visual Studio use them as startup project (first project in .sln)
var insertPosition = (solutionProject.Type == ProjectType.Executable && solutionProject.Platform == PlatformType.Windows)
? 0
: VSSolution.Projects.Count;
VSSolution.Projects.Insert(insertPosition, solutionProject.VSProject);


0 comments on commit b226444

Please sign in to comment.
You can’t perform that action at this time.