Skip to content

Commit c0815eb

Browse files
authored
Merge branch 'master' into merge/release/3.0-preview3-to-master
2 parents 2f9a04a + 4aad754 commit c0815eb

File tree

744 files changed

+78478
-37277
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

744 files changed

+78478
-37277
lines changed

.azure/pipelines/ci.yml

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -162,9 +162,11 @@ jobs:
162162
--arch x64 \
163163
-e KOREBUILD_SKIP_INSTALL_NETFX=0 \
164164
--no-restore \
165+
--no-build-deps \
165166
/t:BuildSharedFx \
166167
/p:BuildRuntimeArchive=false \
167-
/p:LinuxInstallerType=deb
168+
/p:LinuxInstallerType=deb \
169+
/bl:artifacts/logs/build.deb.binlog
168170
displayName: Build Debian installers
169171
- script: |
170172
rm -rf .dotnet/
@@ -173,9 +175,12 @@ jobs:
173175
--ci --pack --all --no-build-nodejs --no-build-java \
174176
--arch x64 \
175177
-e KOREBUILD_SKIP_INSTALL_NETFX=0 \
178+
--no-restore \
179+
--no-build-deps \
176180
/t:BuildSharedFx \
177181
/p:BuildRuntimeArchive=false \
178-
/p:LinuxInstallerType=rpm
182+
/p:LinuxInstallerType=rpm \
183+
/bl:artifacts/logs/build.rpm.binlog
179184
displayName: Build RPM installers
180185
afterBuild:
181186
# Remove packages that are not rid-specific.
@@ -292,6 +297,12 @@ jobs:
292297
beforeBuild:
293298
- powershell: "& ./src/Servers/IIS/tools/UpdateIISExpressCertificate.ps1; & ./src/Servers/IIS/tools/update_schema.ps1"
294299
displayName: Setup IISExpress test certificates and schema
300+
- powershell: "& ./.azure/pipelines/tools/SetupTestEnvironment.ps1 Setup signalrclienttests.exe"
301+
displayName: Start AppVerifier
302+
afterBuild:
303+
- powershell: "& ./.azure/pipelines/tools/SetupTestEnvironment.ps1 Shutdown signalrclienttests.exe"
304+
displayName: Stop AppVerifier
305+
condition: always()
295306
artifacts:
296307
- name: Windows_Test_Logs
297308
path: artifacts/logs/

.azure/pipelines/jobs/default-build.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,7 @@ jobs:
103103
BuildScriptArgs: ${{ parameters.buildArgs }}
104104
BuildConfiguration: ${{ parameters.configuration }}
105105
BuildDirectory: ${{ parameters.buildDirectory }}
106+
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true
106107
TeamName: AspNetCore
107108
${{ if eq(parameters.agentOs, 'Windows') }}:
108109
JAVA_HOME: $(Agent.BuildDirectory)\.tools\jdk

.azure/pipelines/signalr-daily-tests.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,11 @@ jobs:
1414
agentOs: Windows
1515
jobName: SignalRDailyTests
1616
jobDisplayName: "SignalR Daily Tests"
17+
beforeBuild:
18+
- powershell: "& ./.azure/pipelines/tools/SetupTestEnvironment.ps1 Setup signalrclienttests.exe"
19+
displayName: Start AppVerifier
20+
afterBuild:
21+
- powershell: "& ./.azure/pipelines/tools/SetupTestEnvironment.ps1 Shutdown signalrclienttests.exe"
22+
displayName: Stop AppVerifier
23+
condition: always()
1724

src/Servers/IIS/tools/SetupTestEnvironment.ps1 renamed to .azure/pipelines/tools/SetupTestEnvironment.ps1

Lines changed: 15 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,21 @@
1-
param($Mode)
2-
3-
# TEMP TEMP TEMP
4-
# While doing https://github.com/aspnet/AspNetCore/pull/5705 I accidentally disabled ANCM on CI machines using
5-
# the registy key. Remove it to allow tests to pass
6-
7-
Remove-Item "HKLM:\SOFTWARE\Microsoft\IIS Extensions\IIS AspNetCore Module V2\Parameters" -ErrorAction Ignore;
1+
param(
2+
[string]$Mode,
3+
[string[]]$exes
4+
)
85

96
if (!($DumpFolder))
107
{
11-
$DumpFolder = "$PSScriptRoot\..\..\..\..\artifacts\logs\dumps"
8+
$DumpFolder = "$PSScriptRoot\..\..\..\artifacts\logs\dumps"
129
}
1310
if (!(Test-Path $DumpFolder))
1411
{
1512
New-Item $DumpFolder -ItemType Directory;
1613
}
1714
$DumpFolder = Resolve-Path $DumpFolder
1815

19-
$LogsFolder = "$PSScriptRoot\..\artifacts\logs"
20-
if (!(Test-Path $LogsFolder))
21-
{
22-
New-Item $LogsFolder -ItemType Directory;
23-
}
24-
$LogsFolder = Resolve-Path $LogsFolder
25-
2616
$werHive = "HKLM:\SOFTWARE\Microsoft\Windows\Windows Error Reporting";
2717
$ldHive = "$werHive\LocalDumps";
2818

29-
3019
function Setup-appverif($application)
3120
{
3221
appverif.exe -enable Exceptions Handles Heaps Leak Locks Memory Threadpool TLS SRWLock -for $application
@@ -70,7 +59,7 @@ function Shutdown-appverif($application)
7059

7160
function Setup-Dumps()
7261
{
73-
if (!(Test-Path $ldHive ))
62+
if (!(Test-Path $ldHive))
7463
{
7564
New-Item -Path $werHive -Name LocalDumps
7665
}
@@ -116,24 +105,27 @@ function Shutdown-Dumps()
116105

117106
if ($Mode -eq "Setup")
118107
{
119-
Setup-appverif w3wp.exe
120-
Setup-appverif iisexpress.exe
108+
foreach ($element in $exes) {
109+
Setup-appverif $element
110+
}
121111

122112
Setup-Dumps;
123113
}
124114

125115
if ($Mode -eq "SetupDumps")
126116
{
127-
Shutdown-appverif w3wp.exe
128-
Shutdown-appverif iisexpress.exe
117+
foreach ($element in $exes) {
118+
Shutdown-appverif $element
119+
}
129120

130121
Setup-Dumps;
131122
}
132123

133124
if ($Mode -eq "Shutdown")
134125
{
135-
Shutdown-appverif w3wp.exe
136-
Shutdown-appverif iisexpress.exe
126+
foreach ($element in $exes) {
127+
Shutdown-appverif $element
128+
}
137129

138130
Shutdown-Dumps;
139131
}

.editorconfig

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,14 @@
11
; EditorConfig to support per-solution formatting.
22
; Use the EditorConfig VS add-in to make this work.
33
; http://editorconfig.org/
4+
;
5+
; Here are some resources for what's supported for .NET/C#
6+
; https://kent-boogaart.com/blog/editorconfig-reference-for-c-developers
7+
; https://docs.microsoft.com/en-us/visualstudio/ide/editorconfig-code-style-settings-reference?view=vs-2017
8+
;
9+
; Be **careful** editing this because some of the rules don't support adding a severity level
10+
; For instance if you change to `dotnet_sort_system_directives_first = true:warning` (adding `:warning`)
11+
; then the rule will be silently ignored.
412

513
; This is the default for the codeline.
614
root = true
@@ -13,7 +21,7 @@ insert_final_newline = true
1321

1422
[*.cs]
1523
indent_size = 4
16-
dotnet_sort_system_directives_first = true:warning
24+
dotnet_sort_system_directives_first = true
1725

1826
[*.{xml,config,*proj,nuspec,props,resx,targets,yml,tasks}]
1927
indent_size = 2

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ StyleCop.Cache
1717
node_modules/
1818
*.snk
1919
.nuget
20+
.packages/
2021
.r
2122
.w
2223
.deps

Directory.Build.props

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66

77
<Authors>Microsoft</Authors>
88
<Company>Microsoft Corporation.</Company>
9-
<RpmPackageVendor>.NET Foundation</RpmPackageVendor>
109
<Copyright>© Microsoft Corporation. All rights reserved.</Copyright>
1110
<NeutralLanguage>en-US</NeutralLanguage>
1211

@@ -31,6 +30,15 @@
3130

3231
<SharedFxProductName>$(Product) $(PackageVersion) Shared Framework</SharedFxProductName>
3332
<SharedFxDescription>Shared Framework for hosting of Microsoft ASP.NET Core applications. It is open source, cross-platform and is supported by Microsoft. We hope you enjoy using it! If you do, please consider joining the active community of developers that are contributing to the project on GitHub ($(RepositoryUrl)). We happily accept issues and PRs.</SharedFxDescription>
33+
34+
<RuntimeInstallerBaseName>aspnetcore-runtime</RuntimeInstallerBaseName>
35+
<TargetingPackInstallerBaseName>aspnetcore-targeting-pack</TargetingPackInstallerBaseName>
36+
<!--
37+
Archives and installers using this prefix are intended for internal-use only.
38+
For example, this .zip is used to handoff bits to partner teams who then incorporate our shared frameworks
39+
into their own installers.
40+
-->
41+
<InternalInstallerBaseName>$(RuntimeInstallerBaseName)-internal</InternalInstallerBaseName>
3442
</PropertyGroup>
3543

3644
<!-- Warnings and errors -->
@@ -62,7 +70,7 @@
6270
<IncludeSourceRevisionInInformationalVersion>false</IncludeSourceRevisionInInformationalVersion>
6371

6472
<!-- These project types are disabled because the presence of a PackageReference causes issues for NuGet. -->
65-
<DisableSourceLink Condition="'$(MSBuildProjectExtension)' == '.zipproj' OR '$(MSBuildProjectExtension)' == '.debproj' OR '$(MSBuildProjectExtension)' == '.rpmproj'">true</DisableSourceLink>
73+
<DisableSourceLink Condition="'$(MSBuildProjectExtension)' == '.debproj' OR '$(MSBuildProjectExtension)' == '.rpmproj'">true</DisableSourceLink>
6674
</PropertyGroup>
6775

6876
<ItemGroup Condition="'$(DisableSourceLink)' != 'true'">
@@ -95,13 +103,17 @@
95103
</SupportedRuntimeIdentifiers>
96104

97105
<!-- Make error messages clickable in VS Code's console -->
98-
<GenerateFullPaths Condition="'$(VSCODE_PID)' != ''">true</GenerateFullPaths>
106+
<GenerateFullPaths Condition="'$(VSCODE_CWD)' != '' OR '$(TERM_PROGRAM)' == 'vscode'">true</GenerateFullPaths>
99107

100108
<!-- Suppress the message about using a preview version of .NET Core SDK. We are okay with this and don't need the warning. -->
101109
<SuppressNETCoreSdkPreviewMessage>true</SuppressNETCoreSdkPreviewMessage>
102110

103111
<!-- Fixes a common error in targets implementing a NoBuild mode. -->
104112
<BuildProjectReferences Condition=" '$(NoBuild)' == 'true' ">false</BuildProjectReferences>
113+
114+
<IsReferenceAssemblyProject>false</IsReferenceAssemblyProject>
115+
<IsReferenceAssemblyProject Condition="$(MSBuildProjectDirectory.EndsWith('ref'))">true</IsReferenceAssemblyProject>
116+
<OutDirName Condition="'$(IsReferenceAssemblyProject)' == 'true'">$(MSBuildProjectName)-ref</OutDirName>
105117
</PropertyGroup>
106118

107119
<Import Project="eng\Versions.props" />
@@ -157,6 +169,8 @@
157169
<IsTestAssetProject Condition="$(RepoRelativeProjectDir.Contains('testassets'))">true</IsTestAssetProject>
158170
<IsSampleProject Condition="$(RepoRelativeProjectDir.Contains('sample'))">true</IsSampleProject>
159171
<IsAnalyzersProject Condition="$(MSBuildProjectName.EndsWith('.Analyzers'))">true</IsAnalyzersProject>
172+
<IsSpecificationTestProject Condition="$(MSBuildProjectName.EndsWith('.Specification.Tests'))">true</IsSpecificationTestProject>
173+
160174
</PropertyGroup>
161175

162176
<Import Project="build\tasks\RepoTasks.tasks" Condition="'$(MSBuildProjectName)' != 'RepoTasks' AND '$(DesignTimeBuild)' != 'true'" />
@@ -174,6 +188,13 @@
174188
<BuildIisNativeProjects Condition="'$(BuildNative)' != 'false' AND '$(TargetOsName)' == 'win' AND ('$(TargetArchitecture)' == 'x86' OR '$(TargetArchitecture)' == 'x64')">true</BuildIisNativeProjects>
175189
<!-- This property is shared by several projects to layout the AspNetCore.App targeting pack for installers -->
176190
<TargetingPackLayoutRoot>$(ArtifactsObjDir)TargetingPack.Layout\$(Configuration)\</TargetingPackLayoutRoot>
191+
<!-- This property is shared by several projects to layout the AspNetCore.App shared framework for installers -->
192+
<SharedFrameworkLayoutRoot>$(ArtifactsObjDir)SharedFx.Layout\$(Configuration)\$(TargetRuntimeIdentifier)\</SharedFrameworkLayoutRoot>
193+
<!-- This property points to a folder which includes both Microsoft.NETCore.App and AspNetCore.App. -->
194+
<RedistSharedFrameworkLayoutRoot>$(ArtifactsObjDir)RedistSharedFx.Layout\$(Configuration)\$(TargetRuntimeIdentifier)\</RedistSharedFrameworkLayoutRoot>
195+
196+
<ArchiveExtension>.tar.gz</ArchiveExtension>
197+
<ArchiveExtension Condition="'$(TargetOsName)' == 'win'">.zip</ArchiveExtension>
177198
</PropertyGroup>
178199

179200
<Import Project="eng\Workarounds.props" />

Directory.Build.targets

Lines changed: 11 additions & 88 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,11 @@
88
-->
99
<IsShippingPackage Condition=" '$(IsShippingPackage)' == '' ">false</IsShippingPackage>
1010

11+
<!--
12+
By default, assemblies which are only in the Microsoft.AspNetCore.App shared framework are not available as NuGet packages.
13+
-->
14+
<IsPackable Condition="'$(IsAspNetCoreApp)' == 'true' AND '$(IsShippingPackage)' != 'true'">false</IsPackable>
15+
1116
<PackageOutputPath Condition=" '$(IsShippingPackage)' == 'true' ">$(ArtifactsShippingPackagesDir)</PackageOutputPath>
1217
<PackageOutputPath Condition=" '$(IsShippingPackage)' != 'true' ">$(ArtifactsNonShippingPackagesDir)</PackageOutputPath>
1318

@@ -22,7 +27,7 @@
2227

2328
<PropertyGroup Condition=" '$(MSBuildProjectExtension)' == '.csproj' ">
2429
<PackageId Condition=" '$(PackageId)' == '' ">$(AssemblyName)</PackageId>
25-
<IsPackable Condition="'$(IsPackable)' == '' AND ( '$(IsTestProject)' == 'true' OR '$(IsTestAssetProject)' == 'true' OR '$(IsBenchmarkProject)' == 'true' OR '$(IsSampleProject)' == 'true' ) ">false</IsPackable>
30+
<IsPackable Condition="'$(IsPackable)' == '' AND ( '$(IsTestProject)' == 'true' OR '$(IsTestAssetProject)' == 'true' OR '$(IsBenchmarkProject)' == 'true' OR '$(IsSampleProject)' == 'true' OR '$(IsReferenceAssemblyProject)' == 'true' ) ">false</IsPackable>
2631
</PropertyGroup>
2732

2833
<Import Project="eng\Baseline.Designer.props" />
@@ -55,11 +60,14 @@
5560

5661
<PropertyGroup>
5762
<!-- Implementation projects are the projects which produce nuget packages or shipping assemblies. -->
58-
<IsImplementationProject Condition=" '$(IsImplementationProject)' == '' AND '$(IsAnalyzersProject)' != 'true' AND '$(IsTestAssetProject)' != 'true' AND '$(IsTestProject)' != 'true' AND '$(IsBenchmarkProject)' != 'true' AND '$(IsSampleProject)' != 'true' ">true</IsImplementationProject>
63+
<IsImplementationProject Condition=" '$(IsImplementationProject)' == '' AND '$(IsAnalyzersProject)' != 'true' AND '$(IsTestAssetProject)' != 'true' AND '$(IsTestProject)' != 'true' AND '$(IsBenchmarkProject)' != 'true' AND '$(IsSampleProject)' != 'true' AND '$(IsReferenceAssemblyProject)' != 'true' ">true</IsImplementationProject>
5964

6065
<!-- This determines whether a project is available as a <Reference> to other projects in this repo. -->
6166
<IsProjectReferenceProvider Condition=" '$(IsProjectReferenceProvider)' == '' AND '$(IsImplementationProject)' == 'true' AND '$(PackAsTool)' != 'true' ">true</IsProjectReferenceProvider>
6267

68+
<HasReferenceAssembly Condition="'$(HasReferenceAssembly)' == '' AND '$(IsProjectReferenceProvider)' == 'true'">true</HasReferenceAssembly>
69+
<HasReferenceAssembly Condition="'$(HasReferenceAssembly)' == ''">false</HasReferenceAssembly>
70+
6371
<!-- Suppress KoreBuild warnings about the mismatch of repo version and local project version. The versioning in this mega repo is sufficiently complicated that KoreBuild's validation isn't helpful. -->
6472
<VerifyVersion>false</VerifyVersion>
6573

@@ -93,91 +101,6 @@
93101
<Import Project="eng\targets\FSharp.Common.targets" Condition="'$(MSBuildProjectExtension)' == '.fsproj'" />
94102
<Import Project="eng\targets\Wix.Common.targets" Condition="'$(MSBuildProjectExtension)' == '.wixproj'" />
95103
<Import Project="eng\targets\Npm.Common.targets" Condition="'$(MSBuildProjectExtension)' == '.npmproj'" />
104+
<Import Project="eng\targets\ReferenceAssembly.targets" Condition=" '$(HasReferenceAssembly)' == 'true' " />
96105

97-
<!-- Prepares the test projects for helix by including xunit and publishing -->
98-
<Target Name="PrepareHelixPayload" Returns="@(HelixDirectory)">
99-
<ItemGroup>
100-
<_TargetFrameworks Remove="@(_TargetFrameworks)" />
101-
<_TargetFrameworks Include="$(TargetFrameworks);$(TargetFramework)" />
102-
</ItemGroup>
103-
104-
<MSBuild Projects="$(MSBuildProjectFullPath)"
105-
Targets="_PrepareHelixPayloadInner"
106-
Properties="TargetFramework=%(_TargetFrameworks.Identity);IsWindowsHelixQueue=$(HelixTargetQueue.Contains('Windows'))">
107-
<Output TaskParameter="TargetOutputs" ItemName="HelixDirectory" />
108-
</MSBuild>
109-
</Target>
110-
111-
<Target Name="_PrepareHelixPayloadInner"
112-
DependsOnTargets="Publish"
113-
Condition="'$(BuildHelixPayload)' == 'true'"
114-
Returns="@(HelixDirectory)">
115-
116-
<ItemGroup>
117-
<HelixDirectory Include="$(MSBuildProjectFullPath)" />
118-
</ItemGroup>
119-
</Target>
120-
121-
<!-- Build the actual helix work items to send to helix queues -->
122-
<Target Name="CreateHelixPayload" Returns="@(HelixPayload)">
123-
<ItemGroup>
124-
<_TargetFrameworks Remove="@(_TargetFrameworks)" />
125-
<_TargetFrameworks Include="$(TargetFrameworks);$(TargetFramework)" />
126-
</ItemGroup>
127-
128-
<MSBuild Projects="$(MSBuildProjectFullPath)"
129-
Targets="_CreateHelixPayloadInner"
130-
Properties="TargetFramework=%(_TargetFrameworks.Identity);IsWindowsHelixQueue=$(HelixTargetQueue.Contains('Windows'))">
131-
<Output TaskParameter="TargetOutputs" ItemName="HelixPayload" />
132-
</MSBuild>
133-
</Target>
134-
135-
<Target Name="CollectXunitConsoleRunner" Condition="'$(TargetFrameworkIdentifier)' == '.NETFramework'">
136-
<PropertyGroup>
137-
<XunitConsoleRunnerDir>$([System.IO.Path]::GetDirectoryName($(XunitConsole472Path)))</XunitConsoleRunnerDir>
138-
</PropertyGroup>
139-
140-
<ItemGroup>
141-
<XunitConsoleRunnerFiles Include="$(XunitConsoleRunnerDir)/**/*" />
142-
</ItemGroup>
143-
144-
<Copy SourceFiles="@(XunitConsoleRunnerFiles)" DestinationFolder="$(PublishDir)" />
145-
</Target>
146-
147-
<Target Name="_CreateHelixPayloadInner"
148-
DependsOnTargets="CollectXunitConsoleRunner"
149-
Condition="($(IsWindowsHelixQueue) OR '$(TargetFrameworkIdentifier)' != '.NETFramework')"
150-
Returns="@(HelixPayload)">
151-
152-
<ConvertToAbsolutePath Paths="$(PublishDir)">
153-
<Output TaskParameter="AbsolutePaths" PropertyName="PublishAbsoluteDir" />
154-
</ConvertToAbsolutePath>
155-
156-
<!-- Windows NetCore -->
157-
<ItemGroup Condition="'$(TargetFrameworkIdentifier)' != '.NETFramework' AND $(IsWindowsHelixQueue)" >
158-
<_CopyItems Include="$(MSBuildThisFileDirectory)eng\helix\vstest\runtests.cmd" />
159-
</ItemGroup>
160-
161-
<!-- Windows NetFramework -->
162-
<ItemGroup Condition="'$(TargetFrameworkIdentifier)' == '.NETFramework' AND $(IsWindowsHelixQueue)" >
163-
<_CopyItems Include="$(MSBuildThisFileDirectory)eng\helix\xunit\runtests.cmd" />
164-
</ItemGroup>
165-
166-
<!-- NonWindows -->
167-
<ItemGroup Condition="!$(IsWindowsHelixQueue)" >
168-
<_CopyItems Include="$(MSBuildThisFileDirectory)eng\helix\vstest\runtests.sh" />
169-
</ItemGroup>
170-
171-
<Copy SourceFiles="@(_CopyItems)" DestinationFolder="$(PublishAbsoluteDir)" />
172-
173-
<ItemGroup>
174-
<HelixPayload Include="$(PublishAbsoluteDir)">
175-
<TestAssembly>$(TargetFileName)</TestAssembly>
176-
<TestName>$(MSBuildProjectName)-$(TargetFramework)</TestName>
177-
<Command Condition="$(IsWindowsHelixQueue)">runtests.cmd $(TargetFileName) $(NETCoreSdkVersion) $(MicrosoftNETCoreAppPackageVersion)</Command>
178-
<Command Condition="!$(IsWindowsHelixQueue)">./runtests.sh $(TargetFileName) $(NETCoreSdkVersion) $(MicrosoftNETCoreAppPackageVersion)</Command>
179-
<TestTimeout>00:30:00</TestTimeout>
180-
</HelixPayload>
181-
</ItemGroup>
182-
</Target>
183106
</Project>

NuGet.config

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,6 @@
99
-->
1010
<add key="dotnet-core" value="https://dotnetfeed.blob.core.windows.net/dotnet-core/index.json" />
1111
<add key="myget.org aspnetcore-tools" value="https://dotnet.myget.org/F/aspnetcore-tools/api/v3/index.json" />
12+
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" />
1213
</packageSources>
1314
</configuration>

build.ps1

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -306,6 +306,7 @@ $MSBuildArguments += "/p:TargetOsName=win"
306306
Import-Module -Force -Scope Local (Join-Path $korebuildPath 'KoreBuild.psd1')
307307

308308
try {
309+
$env:KOREBUILD_KEEPGLOBALJSON = 1
309310
Set-KoreBuildSettings -ToolsSource $ToolsSource -DotNetHome $DotNetHome -RepoPath $PSScriptRoot -ConfigFile $ConfigFile -CI:$CI
310311
if ($ForceCoreMsbuild) {
311312
$global:KoreBuildSettings.MSBuildType = 'core'
@@ -315,4 +316,5 @@ try {
315316
finally {
316317
Remove-Module 'KoreBuild' -ErrorAction Ignore
317318
Remove-Item env:DOTNET_HOME
319+
Remove-Item env:KOREBUILD_KEEPGLOBALJSON
318320
}

0 commit comments

Comments
 (0)