|
1 | 1 | <Project> |
2 | 2 | <PropertyGroup> |
3 | | - |
| 3 | + <!-- Disable Visual Studio's project up to date checking so that a build with build.ps1 will not result in a re-build --> |
| 4 | + <DisableFastUpToDateCheck>true</DisableFastUpToDateCheck> |
4 | 5 | <!-- |
5 | 6 | MSB3277/MSB3243: Assembly version conflicts are BUILD ERRORS. |
6 | 7 | CPM + transitive pinning (Directory.Packages.props) prevents version drift. |
|
66 | 67 | Version declarations are centrally managed in Directory.Packages.props. |
67 | 68 | --> |
68 | 69 | <PropertyGroup Label="AssemblyInfo Policy"> |
69 | | - <!-- |
| 70 | + <!-- TODO: Fix the location of the Include and remove the CommonAssemblyInfo from all .csproj files |
70 | 71 | CommonAssemblyInfoTemplate Policy: |
71 | 72 | All managed projects must link Src/CommonAssemblyInfo.cs to ensure consistent versioning and metadata. |
72 | 73 | When linking the template, disable SDK auto-generation to prevent CS0579 duplicate attribute errors. |
|
117 | 118 |
|
118 | 119 | <ItemGroup> |
119 | 120 | <Compile Remove="**/*.template.cs" /> |
120 | | - <!-- |
121 | | - Test Exclusion Policy (Pattern A): |
122 | | - All test code must be explicitly excluded using the pattern: |
123 | | - <Compile Remove="<ProjectName>Tests/**" /> |
124 | | - <None Remove="<ProjectName>Tests/**" /> |
125 | | -
|
126 | | - Wildcards (e.g. *Tests/**) are NOT allowed. |
127 | | - Nested test folders must also be explicitly excluded. |
128 | | - --> |
129 | 121 | </ItemGroup> |
130 | 122 |
|
131 | | - <!-- |
132 | | - Stale obj/ Folder Policy: |
133 | | - Since SDK migration, intermediate output uses centralized location: $(FwRoot)Obj/$(Configuration)/<ProjectName>/ |
134 | | -
|
135 | | - Old per-project obj/ folders (Src/**/obj/) should not exist. |
136 | | - If they do, build.ps1 automatically removes them before building. |
137 | | -
|
138 | | - IMPORTANT: Do NOT use ItemGroup Remove patterns here to exclude stale files. |
139 | | - The SDK's GenerateTargetFrameworkMonikerAttribute target adds files AFTER |
140 | | - Directory.Build.props is evaluated, so such patterns are ineffective. |
141 | | - The cleanup in build.ps1 is the correct solution. |
142 | | -
|
143 | | - If you encounter CS0579 duplicate attribute errors, run: |
144 | | - Get-ChildItem -Path Src -Filter obj -Directory -Recurse | Remove-Item -Recurse -Force |
145 | | - Or simply run .\build.ps1 which does this automatically. |
146 | | - --> |
147 | | - <!-- |
148 | | - WPF/XAML Compilation Memory Optimization: |
149 | | - XAML compilation can cause OOM errors in memory-constrained builds (parallel builds). |
150 | | - These settings help reduce memory pressure: |
151 | | - - XamlDebuggingInformation: Disable extra debugging info in Release (smaller assemblies) |
152 | | - - UseRidGraph: Use RID graph directly instead of creating temp projects |
153 | | - --> |
154 | 123 | <PropertyGroup Condition="'$(UseWPF)' == 'true'"> |
155 | 124 | <XamlDebuggingInformation Condition="'$(Configuration)' == 'Release'">false</XamlDebuggingInformation> |
156 | 125 | <UseRidGraph>true</UseRidGraph> |
|
177 | 146 | --> |
178 | 147 | <WarningsNotAsErrors>$(WarningsNotAsErrors);CS0168;CS0169;CS0219;CS0414;CS0649;168;169;219;414;649</WarningsNotAsErrors> |
179 | 148 | </PropertyGroup> |
180 | | - |
181 | | - <!-- |
182 | | - Test infrastructure PackageReferences have moved to Src/Directory.Build.props |
183 | | - to scope them to Src/ projects only (Build/Src FwBuildTasks manages its own test versions). |
184 | | - Version declarations are centrally managed in Directory.Packages.props. |
185 | | - --> |
186 | | - |
187 | 149 | <!-- |
188 | 150 | Shared test assembly attributes: SLDR offline mode, ICU initialization, registry redirect, etc. |
189 | 151 | This is applied to all test projects that don't already include the file. |
|
0 commit comments