msbuild - Solution files conditional elements -


is possible make elements in visual studio file conditional.

although oddly .sln not in msbuild or xml format love similar syntax

project("{fae04ec0-301f-11d3-bf4b-00c04f79efbc}") = "helloproj", "helloproj.csproj", "{61729087-eea0-4c80-bf72-4205970239f9}" endproject

would become

project( condition="some condition stuff" "{fae04ec0-301f-11d3-bf4b-00c04f79efbc}") = "helloproj", ...

so if "some condition stuff" evaluated false project helloproj not included when open solution. doubt feasible, i'm not sure if solution file has concept of properties/variable thought ask anyway.

nothing exists aware of remove project being loaded when open solution. don't think intent of solution file, rather if need include/exclude projects based on criteria @ open time it's safe consider using multiple solution files each solution contains correct projects situation.

however, c#/c++/c projects can use configuration manager modify build , deploy behaviour each project in solution based on platform , configuration chosen. in solution explorer, right-click on solution , choose 'configuration manager...'.

screen capture of configuration manager in use turn off building project in solution cpu platform , debug configuration


Comments

Popular posts from this blog

javascript - Chart.js (Radar Chart) different scaleLineColor for each scaleLine -

apache - Error with PHP mail(): Multiple or malformed newlines found in additional_header -

java - Android – MapFragment overlay button shadow, just like MyLocation button -