Skip to content

Commit d8b0b6a

Browse files
committed
Improve the text
1 parent 431dd53 commit d8b0b6a

File tree

1 file changed

+12
-10
lines changed

1 file changed

+12
-10
lines changed

src/Microsoft.Net.Sdk.Compilers.Toolset/Microsoft.Net.Sdk.Compilers.Toolset.csproj

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,23 @@
33
<PropertyGroup>
44
<TargetFramework>$(SdkTargetFramework)</TargetFramework>
55
<Description><![CDATA[
6-
Transport package for Microsoft.Net.Compilers.Toolset.Framework assemblies. For internal use only: do not reference this package directly as it is explicitly not supported in that fashion.
6+
Transport package for Microsoft.Net.Compilers.Toolset.Framework assemblies. For internal use only:
7+
do not reference this package directly as it is explicitly not supported in that fashion.
78
89
This package is automatically downloaded when your MSBuild version does not match your SDK version.
9-
Then your project uses the compiler version matching your SDK version instead of the one bundled with MSBuild.
10+
Then the package is used to build your project with the compiler version matching your SDK version
11+
instead of the one bundled with MSBuild.
1012
11-
If you want to disable this behavior, set property `BuildWithNetFrameworkHostedCompiler` to `false`
12-
in your `.csproj` or `Directory.Build.props` file, for example:
13+
If you want to download this package using the dotnet CLI, you can use the following command:
1314
14-
```csproj
15-
<Project>
16-
<PropertyGroup>
17-
<BuildWithNetFrameworkHostedCompiler>false</BuildWithNetFrameworkHostedCompiler>
18-
</ProperyGroup>
19-
</Project>
2015
```
16+
dotnet restore /p:BuildWithNetFrameworkHostedCompiler=true
17+
```
18+
19+
If you want to disable automatic download and use of this package, set property `BuildWithNetFrameworkHostedCompiler` to `false`
20+
(for example, in your `.csproj` or `Directory.Build.props` file).
21+
However, be aware that you will be building with mismatched compiler and SDK versions.
22+
That is explicitly not supported and can lead to errors (especially with analyzers and source generators).
2123
]]></Description>
2224
<IsPackable>true</IsPackable>
2325
<IncludeBuildOutput>false</IncludeBuildOutput>

0 commit comments

Comments
 (0)