-
Notifications
You must be signed in to change notification settings - Fork 42
Expand file tree
/
Copy pathDirectory.Build.props
More file actions
156 lines (136 loc) · 6.41 KB
/
Directory.Build.props
File metadata and controls
156 lines (136 loc) · 6.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
<Project>
<!--
Centralized Build Configurations
All Extended Toolkit projects use these configurations
-->
<PropertyGroup>
<Configurations>Debug;Release;ReleaseLite;ReleaseAll;Canary;CanaryLite;CanaryAll;Nightly;NightlyLite;NightlyAll</Configurations>
</PropertyGroup>
<!--
Centralized Target Framework Monikers (TFMs) Configuration
All Extended Toolkit projects use these TFMs unless explicitly overridden
-->
<!--
Target Framework Monikers (TFMs) Configuration
Dynamic TFM selection based on build configuration using Choose pattern
-->
<Choose>
<!-- Full framework support for Release, Nightly, Canary, and Debug configurations -->
<When Condition="'$(Configuration)' == 'Release' Or '$(Configuration)' == 'Nightly' Or '$(Configuration)' == 'Canary' Or '$(Configuration)' == 'Debug'">
<PropertyGroup>
<ActiveExtendedToolkitTFMs>net472;net48;net481;net8.0-windows7.0;net9.0-windows7.0;net10.0-windows7.0</ActiveExtendedToolkitTFMs>
</PropertyGroup>
</When>
<!-- Lite framework support for ReleaseLite, CanaryLite, and NightlyLite configurations -->
<When Condition="'$(Configuration)' == 'ReleaseLite' Or '$(Configuration)' == 'CanaryLite' Or '$(Configuration)' == 'NightlyLite'">
<PropertyGroup>
<ActiveExtendedToolkitTFMs>net48;net481;net8.0-windows7.0;net9.0-windows7.0;net10.0-windows7.0</ActiveExtendedToolkitTFMs>
</PropertyGroup>
</When>
<!-- All configurations (Full+Lite) - Uses Full TFMs, but helper scripts build both -->
<When Condition="'$(Configuration)' == 'ReleaseAll' Or '$(Configuration)' == 'CanaryAll' Or '$(Configuration)' == 'NightlyAll'">
<PropertyGroup>
<ActiveExtendedToolkitTFMs>net472;net48;net481;net8.0-windows7.0;net9.0-windows7.0;net10.0-windows7.0</ActiveExtendedToolkitTFMs>
</PropertyGroup>
</When>
<!-- Default: Full framework support for any other configurations -->
<Otherwise>
<PropertyGroup>
<ActiveExtendedToolkitTFMs>net472;net48;net481;net8.0-windows7.0;net9.0-windows7.0;net10.0-windows7.0</ActiveExtendedToolkitTFMs>
</PropertyGroup>
</Otherwise>
</Choose>
<!--
Legacy TFM properties for backward compatibility and reference
These can be used by projects that need explicit TFM sets
-->
<PropertyGroup>
<!-- Full framework support (all projects by default) -->
<ExtendedToolkitTFMs>net472;net48;net481;net8.0-windows7.0;net9.0-windows7.0;net10.0-windows7.0</ExtendedToolkitTFMs>
<!-- Lite framework support (excludes net472 for smaller packages) -->
<ExtendedToolkitLiteTFMs>net48;net481;net8.0-windows7.0;net9.0-windows7.0;net10.0-windows7.0</ExtendedToolkitLiteTFMs>
<!-- Modern frameworks only (net8+) -->
<ExtendedToolkitModernTFMs>net8.0-windows7.0;net9.0-windows7.0;net10.0-windows7.0</ExtendedToolkitModernTFMs>
<!-- Legacy frameworks only (net4x) -->
<ExtendedToolkitLegacyTFMs>net472;net48;net481</ExtendedToolkitLegacyTFMs>
</PropertyGroup>
<!--
Version Configuration
Dynamic versioning based on build configuration
-->
<Choose>
<!-- Canary configurations (beta releases) -->
<When Condition="'$(Configuration)' == 'Canary' OR '$(Configuration)' == 'CanaryLite' OR '$(Configuration)' == 'CanaryAll'">
<PropertyGroup>
<Minor>$([System.DateTime]::Now.ToString(yy))</Minor>
<Build>$([System.DateTime]::Now.ToString(MM))</Build>
<Revision>$([System.DateTime]::Now.get_DayOfYear().ToString())</Revision>
<!--Version layout schema:
80 = Major
23 = Minor - Year of release
01 = Build - Month of release
1 = Revision - Day of release (day of year)
-beta = Indicates a pre-release package
-->
<LibraryVersion>80.$(Minor).$(Build).$(Revision)</LibraryVersion>
<!--https://docs.microsoft.com/en-us/nuget/create-packages/prerelease-packages-->
<PackageVersion>80.$(Minor).$(Build).$(Revision)-beta</PackageVersion>
</PropertyGroup>
</When>
<!-- Nightly configurations (alpha releases) -->
<When Condition="'$(Configuration)' == 'Nightly' OR '$(Configuration)' == 'NightlyLite' OR '$(Configuration)' == 'NightlyAll'">
<PropertyGroup>
<Minor>$([System.DateTime]::Now.ToString(yy))</Minor>
<Build>$([System.DateTime]::Now.ToString(MM))</Build>
<Revision>$([System.DateTime]::Now.get_DayOfYear().ToString())</Revision>
<!--Version layout schema:
80 = Major
23 = Minor - Year of release
01 = Build - Month of release
1 = Revision - Day of release (day of year)
-alpha = Indicates a pre-release package
-->
<LibraryVersion>80.$(Minor).$(Build).$(Revision)</LibraryVersion>
<!--Nightly-->
<!--https://docs.microsoft.com/en-us/nuget/create-packages/prerelease-packages-->
<PackageVersion>80.$(Minor).$(Build).$(Revision)-alpha</PackageVersion>
</PropertyGroup>
</When>
<!-- Release configurations (stable releases) -->
<When Condition="'$(Configuration)' == 'Release' OR '$(Configuration)' == 'ReleaseLite' OR '$(Configuration)' == 'ReleaseAll'">
<PropertyGroup>
<Minor>$([System.DateTime]::Now.ToString(yy))</Minor>
<Build>$([System.DateTime]::Now.ToString(MM))</Build>
<Revision>$([System.DateTime]::Now.get_DayOfYear().ToString())</Revision>
<!--Version layout schema:
80 = Major
23 = Minor - Year of release
01 = Build - Month of release
1 = Revision - Day of release (day of year)
-->
<LibraryVersion>80.$(Minor).$(Build).$(Revision)</LibraryVersion>
<!--https://docs.microsoft.com/en-us/nuget/create-packages/prerelease-packages-->
<!--Release/ReleaseLite/ReleaseAll (stable packages)-->
<PackageVersion>80.$(Minor).$(Build).$(Revision)</PackageVersion>
</PropertyGroup>
</When>
<!-- Default: Same as Release for Debug and any other configurations -->
<Otherwise>
<PropertyGroup>
<Minor>$([System.DateTime]::Now.ToString(yy))</Minor>
<Build>$([System.DateTime]::Now.ToString(MM))</Build>
<Revision>$([System.DateTime]::Now.get_DayOfYear().ToString())</Revision>
<!--Version layout schema:
80 = Major
23 = Minor - Year of release
01 = Build - Month of release
1 = Revision - Day of release (day of year)
-->
<LibraryVersion>80.$(Minor).$(Build).$(Revision)</LibraryVersion>
<!--https://docs.microsoft.com/en-us/nuget/create-packages/prerelease-packages-->
<!--Debug and other configurations-->
<PackageVersion>80.$(Minor).$(Build).$(Revision)</PackageVersion>
</PropertyGroup>
</Otherwise>
</Choose>
</Project>