Skip to content

Commit 7ff1082

Browse files
authored
Replace DOTNET_SKIP_FIRST_TIME_EXPERIENCE with DOTNET_NOLOGO (#121326)
DOTNET_SKIP_FIRST_TIME_EXPERIENCE was completely removed in .NET Core 3.0 and DOTNET_NOLOGO was reintroduced as its replacement in .NET Core 3.1 to only suppress the First Time Use Experience message. See https://learn.microsoft.com/en-us/dotnet/core/tools/dotnet-environment-variables#dotnet_nologo
1 parent 96acc3c commit 7ff1082

File tree

8 files changed

+10
-10
lines changed

8 files changed

+10
-10
lines changed

dotnet.cmd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ set Platform=
1616
:: Don't resolve runtime, shared framework, or SDK from other locations to ensure build determinism
1717
set DOTNET_MULTILEVEL_LOOKUP=0
1818

19-
:: Disable first run since we want to control all package sources
20-
set DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
19+
:: Suppress the .NET startup banner
20+
set DOTNET_NOLOGO=1
2121

2222
call "%dotnetPath%\dotnet.exe" %*

dotnet.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ scriptroot="$( cd -P "$( dirname "$source" )" && pwd )"
1515
# Don't resolve runtime, shared framework, or SDK from other locations to ensure build determinism
1616
export DOTNET_MULTILEVEL_LOOKUP=0
1717

18-
# Disable first run since we want to control all package sources
19-
export DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
18+
# Suppress the .NET startup banner
19+
export DOTNET_NOLOGO=1
2020

2121
source $scriptroot/eng/common/tools.sh
2222

src/coreclr/scripts/superpmi_aspnet.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ def build_and_run(coreclr_args):
138138
# install dotnet 8.0
139139
run_command([dotnet_install_script_path, "-Version", "8.0.0"], temp_location, _exit_on_fail=True)
140140
os.environ['DOTNET_MULTILEVEL_LOOKUP'] = '0'
141-
os.environ['DOTNET_SKIP_FIRST_TIME_EXPERIENCE'] = '1'
141+
os.environ['DOTNET_NOLOGO'] = '1'
142142
dotnet_path = path.join(source_directory, ".dotnet")
143143
dotnet_exe = path.join(dotnet_path, "dotnet.exe") if is_windows else path.join(dotnet_path, "dotnet")
144144
# run_command([dotnet_exe, "--info"], temp_location, _exit_on_fail=True)

src/installer/tests/TestUtils/DotNetCli.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ public Command Exec(string command, params string[] args)
4646
newArgs.Insert(0, command);
4747

4848
return Command.Create(DotnetExecutablePath, newArgs)
49-
.EnvironmentVariable("DOTNET_SKIP_FIRST_TIME_EXPERIENCE", "1")
49+
.EnvironmentVariable("DOTNET_NOLOGO", "1")
5050
.MultilevelLookup(false); // Avoid looking at machine state by default
5151
}
5252
}

src/libraries/sendtohelix-wasm.targets

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828

2929
<HelixPreCommand Include="$(EnvVarCommand) &quot;XUnitTraitArg=$(_XUnitTraitArg)&quot;" />
3030
<HelixPreCommand Include="$(EnvVarCommand) &quot;SDK_DIR_NAME=$(SdkForWorkloadTestingDirName)&quot;" />
31-
<HelixPreCommand Include="$(EnvVarCommand) &quot;DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1&quot;" />
31+
<HelixPreCommand Include="$(EnvVarCommand) &quot;DOTNET_NOLOGO=1&quot;" />
3232
<HelixPreCommand Include="$(EnvVarCommand) &quot;DOTNET_SKIP_WORKLOAD_INTEGRITY_CHECK=1&quot;" />
3333
</ItemGroup>
3434

src/mono/wasm/Wasm.Build.Tests/Common/BuildEnvironment.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ public BuildEnvironment()
124124
EnvVars["DOTNET_ROOT"] = sdkForWorkloadPath;
125125
EnvVars["DOTNET_INSTALL_DIR"] = sdkForWorkloadPath;
126126
EnvVars["DOTNET_MULTILEVEL_LOOKUP"] = "0";
127-
EnvVars["DOTNET_SKIP_FIRST_TIME_EXPERIENCE"] = "1";
127+
EnvVars["DOTNET_NOLOGO"] = "1";
128128
EnvVars["PATH"] = $"{sdkForWorkloadPath}{Path.PathSeparator}{Environment.GetEnvironmentVariable("PATH")}";
129129
EnvVars["EM_WORKAROUND_PYTHON_BUG_34780"] = "1";
130130

src/mono/wasm/Wasm.Build.Tests/Common/RunCommand.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,6 @@ public RunCommand(BuildEnvironment buildEnv, ITestOutputHelper _testOutput, stri
1414
WithEnvironmentVariable("DOTNET_ROOT", Path.GetDirectoryName(buildEnv.DotNet)!);
1515
WithEnvironmentVariable("DOTNET_INSTALL_DIR", Path.GetDirectoryName(buildEnv.DotNet)!);
1616
WithEnvironmentVariable("DOTNET_MULTILEVEL_LOOKUP", "0");
17-
WithEnvironmentVariable("DOTNET_SKIP_FIRST_TIME_EXPERIENCE", "1");
17+
WithEnvironmentVariable("DOTNET_NOLOGO", "1");
1818
}
1919
}

src/mono/wasm/Wasm.Build.Tests/Common/ToolCommand.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ private Process CreateProcess(string executable, string args)
165165
};
166166

167167
psi.Environment["DOTNET_MULTILEVEL_LOOKUP"] = "0";
168-
psi.Environment["DOTNET_SKIP_FIRST_TIME_EXPERIENCE"] = "1";
168+
psi.Environment["DOTNET_NOLOGO"] = "1";
169169

170170
// runtime repo sets this, which interferes with the tests
171171
psi.RemoveEnvironmentVariables("MSBuildSDKsPath");

0 commit comments

Comments
 (0)